aboutsummaryrefslogtreecommitdiff
path: root/gcc/go/gofrontend/parse.h
diff options
context:
space:
mode:
authorIan Lance Taylor <iant@golang.org>2021-01-04 21:40:29 -0800
committerIan Lance Taylor <iant@golang.org>2021-01-18 16:40:06 -0800
commitc907e4394133b3f4b58feccfb3a415f9ae5ee1f4 (patch)
treea2a082a30790441b19730f20339b73312cf719f0 /gcc/go/gofrontend/parse.h
parentef1f8ee67d41689ddd3b6babf8fab6b4dec60c10 (diff)
downloadgcc-c907e4394133b3f4b58feccfb3a415f9ae5ee1f4.zip
gcc-c907e4394133b3f4b58feccfb3a415f9ae5ee1f4.tar.gz
gcc-c907e4394133b3f4b58feccfb3a415f9ae5ee1f4.tar.bz2
compiler: read embedcfg files, parse go:embed directives
This change reads go:embed directives and attaches them to variables. We still don't do anything with the directives. This change also reads the file passed in the -fgo-embedcfg option. Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/281533
Diffstat (limited to 'gcc/go/gofrontend/parse.h')
-rw-r--r--gcc/go/gofrontend/parse.h15
1 files changed, 8 insertions, 7 deletions
diff --git a/gcc/go/gofrontend/parse.h b/gcc/go/gofrontend/parse.h
index 4a5a4b8..2c3c505 100644
--- a/gcc/go/gofrontend/parse.h
+++ b/gcc/go/gofrontend/parse.h
@@ -181,16 +181,17 @@ class Parse
void method_spec(Typed_identifier_list*);
void declaration();
bool declaration_may_start_here();
- void decl(void (Parse::*)(void*, unsigned int), void*, unsigned int pragmas);
- void list(void (Parse::*)(void*, unsigned int), void*, bool);
+ void decl(void (Parse::*)(unsigned int, std::vector<std::string>*),
+ unsigned int pragmas, std::vector<std::string>* embeds);
+ void list(void (Parse::*)(unsigned int, std::vector<std::string>*), bool);
void const_decl();
void const_spec(int, Type**, Expression_list**);
void type_decl(unsigned int pragmas);
- void type_spec(void*, unsigned int pragmas);
- void var_decl();
- void var_spec(void*, unsigned int pragmas);
+ void type_spec(unsigned int pragmas, std::vector<std::string>*);
+ void var_decl(std::vector<std::string>* embeds);
+ void var_spec(unsigned int pragmas, std::vector<std::string>*);
void init_vars(const Typed_identifier_list*, Type*, Expression_list*,
- bool is_coloneq, Location);
+ bool is_coloneq, std::vector<std::string>*, Location);
bool init_vars_from_call(const Typed_identifier_list*, Type*, Expression*,
bool is_coloneq, Location);
bool init_vars_from_map(const Typed_identifier_list*, Type*, Expression*,
@@ -277,7 +278,7 @@ class Parse
void goto_stat();
void package_clause();
void import_decl();
- void import_spec(void*, unsigned int pragmas);
+ void import_spec(unsigned int pragmas, std::vector<std::string>*);
// Skip past an error looking for a semicolon or OP. Return true if
// all is well, false if we found EOF.