projects
/
uebersetzerbau-ss10.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
394a3c9
)
ag: namen geaendert und debug meldung fix
author
Bernhard Urban
<lewurm@gmail.com>
Tue, 6 Apr 2010 12:19:10 +0000
(14:19 +0200)
committer
Bernhard Urban
<lewurm@gmail.com>
Tue, 6 Apr 2010 12:19:10 +0000
(14:19 +0200)
ag/parser.y
patch
|
blob
|
history
ag/symtable.c
patch
|
blob
|
history
diff --git
a/ag/parser.y
b/ag/parser.y
index 494e6dfbde43f9dbae68fae328bced2fa9912564..7df16d2f1ea6c67f299a0b07c0e5c1fa84366bbf 100644
(file)
--- a/
ag/parser.y
+++ b/
ag/parser.y
@@
-25,7
+25,7
@@
* s .. symbols */
@attributes { char *name; } IDENT
@attributes { struct symbol *f; struct symbol *s; } Program
* s .. symbols */
@attributes { char *name; } IDENT
@attributes { struct symbol *f; struct symbol *s; } Program
-@attributes { struct symbol *f; }
Idents
Structdef Parms
+@attributes { struct symbol *f; }
FeldID
Structdef Parms
@attributes { struct symbol *s; } Methoddef Statseq Lexpr Expr Minusterm Multerm Orterm
Term Exprs Feld
@attributes { struct symbol *sin; struct symbol *sout; } Statement
@attributes { struct symbol *s; } Methoddef Statseq Lexpr Expr Minusterm Multerm Orterm
Term Exprs Feld
@attributes { struct symbol *sin; struct symbol *sout; } Statement
@@
-65,9
+65,9
@@
Methoddef:
;
Structdef:
;
Structdef:
- STRUCT
Idents
END
+ STRUCT
FeldID
END
@{
@{
- @i @Structdef.f@ = @
Idents
.f@;
+ @i @Structdef.f@ = @
FeldID
.f@;
@}
;
@}
;
@@
-84,15
+84,15
@@
Parms:
@}
;
@}
;
-
Idents
:
- IDENT
Idents
+
FeldID
:
+ IDENT
FeldID
@{
@{
- @i @
Idents.0.f@ = tab_add_symbol(@Idents
.1.f@, @IDENT.name@, S_FIELD, 1);
+ @i @
FeldID.0.f@ = tab_add_symbol(@FeldID
.1.f@, @IDENT.name@, S_FIELD, 1);
@}
|
@{
@}
|
@{
- @i @
Idents
.f@ = new_tab();
+ @i @
FeldID
.f@ = new_tab();
@}
;
@}
;
diff --git
a/ag/symtable.c
b/ag/symtable.c
index 9c53557159fd9caf515e3167e51007db84bb9ec5..8c175e5e0421d1e15cd31e1c81f50fe560dc4402 100755
(executable)
--- a/
ag/symtable.c
+++ b/
ag/symtable.c
@@
-124,7
+124,7
@@
void check(struct symbol *tab, char *ident, short type)
{
struct symbol *elm;
#ifdef DD
{
struct symbol *elm;
#ifdef DD
- printf("check
_variable
: tab(%08X), ident(%s), type(%i), elm(%08X)\n", tab, ident, type, elm);
+ printf("check: tab(%08X), ident(%s), type(%i), elm(%08X)\n", tab, ident, type, elm);
#endif
if(type == S_VAR) {
#endif
if(type == S_VAR) {