]> Cypherpunks repositories - gostls13.git/commitdiff
- created new dir (gosrc) for go-based front-end
authorRobert Griesemer <gri@golang.org>
Fri, 11 Jul 2008 01:05:00 +0000 (18:05 -0700)
committerRobert Griesemer <gri@golang.org>
Fri, 11 Jul 2008 01:05:00 +0000 (18:05 -0700)
- adjusted makefiles

SVN=126763

usr/gri/gosrc/globals.go [moved from usr/gri/src/globals.go with 98% similarity]
usr/gri/gosrc/object.go [moved from usr/gri/src/object.go with 100% similarity]
usr/gri/gosrc/parser.go [moved from usr/gri/src/parser.go with 99% similarity]
usr/gri/gosrc/scanner.go [moved from usr/gri/src/scanner.go with 100% similarity]
usr/gri/gosrc/scope.go [moved from usr/gri/src/scope.go with 100% similarity]
usr/gri/gosrc/test_parser.go [moved from usr/gri/src/test_parser.go with 100% similarity]
usr/gri/gosrc/test_scanner.go [moved from usr/gri/src/test_scanner.go with 100% similarity]
usr/gri/gosrc/type.go [moved from usr/gri/src/type.go with 100% similarity]

similarity index 98%
rename from usr/gri/src/globals.go
rename to usr/gri/gosrc/globals.go
index f8d0c116b06bf818da82e961b6b1dcf8ea1f5859..986fbe82cb5ae3aadbc5c7b0ea2e6b42b73e10af 100644 (file)
@@ -2,7 +2,7 @@
 // Use of this source code is governed by a BSD-style
 // license that can be found in the LICENSE file.
 
-package Globals;
+package Globals
 
 
 // The following types should really be in their respective files
@@ -49,6 +49,7 @@ type Scope struct {
 }
 
 
+/*
 func (scope *Scope) Lookup(ident string) *Object {
        panic "UNIMPLEMENTED";
        return nil;
@@ -64,3 +65,4 @@ func (scope *Scope) InsertImport(obj *Object) *Object {
        panic "UNIMPLEMENTED";
        return nil;
 }
+*/
similarity index 99%
rename from usr/gri/src/parser.go
rename to usr/gri/gosrc/parser.go
index 49b0f6ab2545f14ce163a8f20f59cd96ad58a96e..0e025f9d390c65cac16cdb6f86967f5e0e8ce400 100644 (file)
@@ -1046,10 +1046,13 @@ func (P *Parser) ParseProgram() {
        P.Trace("Program");
        P.Expect(Scanner.PACKAGE);
        P.ParseIdent();
+       P.Optional(Scanner.SEMICOLON);
+       
        for P.tok == Scanner.IMPORT {
                P.ParseImportDecl();
                P.Optional(Scanner.SEMICOLON);
        }
+       
        for P.tok != Scanner.EOF {
                P.ParseDeclaration();
                P.Optional(Scanner.SEMICOLON);
similarity index 100%
rename from usr/gri/src/scope.go
rename to usr/gri/gosrc/scope.go
similarity index 100%
rename from usr/gri/src/type.go
rename to usr/gri/gosrc/type.go