summaryrefslogtreecommitdiff
path: root/gcc/go/gofrontend/gogo.h
diff options
context:
space:
mode:
authorbstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4>2014-01-23 11:48:32 +0000
committerbstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4>2014-01-23 11:48:32 +0000
commitf6fc17d03f28a94e35a53d0562595ea179ae2629 (patch)
treee32f9a0a6bdc05a424906b384d8c31c4fa78eb35 /gcc/go/gofrontend/gogo.h
parent8e6ce8a843f5da1c63f8e21c58188e7b7f1a471f (diff)
downloadgcc-f6fc17d03f28a94e35a53d0562595ea179ae2629.tar.gz
2014-01-23 Basile Starynkevitch <basile@starynkevitch.net>
{{merge using svnmerge.py with trunk GCC 4.9 svn rev.206958. All is well compiled.}} git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/melt-branch@206959 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/go/gofrontend/gogo.h')
-rw-r--r--gcc/go/gofrontend/gogo.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/gcc/go/gofrontend/gogo.h b/gcc/go/gofrontend/gogo.h
index a9a56815c17..3f2808781b7 100644
--- a/gcc/go/gofrontend/gogo.h
+++ b/gcc/go/gofrontend/gogo.h
@@ -487,6 +487,14 @@ class Gogo
void
lower_constant(Named_object*);
+ // Flatten all the statements in a block.
+ void
+ flatten_block(Named_object* function, Block*);
+
+ // Flatten an expression.
+ void
+ flatten_expression(Named_object* function, Statement_inserter*, Expression**);
+
// Create all necessary function descriptors.
void
create_function_descriptors();
@@ -531,6 +539,10 @@ class Gogo
void
order_evaluations();
+ // Flatten parse tree.
+ void
+ flatten();
+
// Build thunks for functions which call recover.
void
build_recover_thunks();
@@ -1447,6 +1459,10 @@ class Variable
void
lower_init_expression(Gogo*, Named_object*, Statement_inserter*);
+ // Flatten the initialization expression after ordering evaluations.
+ void
+ flatten_init_expression(Gogo*, Named_object*, Statement_inserter*);
+
// A special case: the init value is used only to determine the
// type. This is used if the variable is defined using := with the
// comma-ok form of a map index or a receive expression. The init
@@ -1580,6 +1596,8 @@ class Variable
bool seen_ : 1;
// True if we have lowered the initialization expression.
bool init_is_lowered_ : 1;
+ // True if we have flattened the initialization expression.
+ bool init_is_flattened_ : 1;
// True if init is a tuple used to set the type.
bool type_from_init_tuple_ : 1;
// True if init is a range clause and the type is the index type.