Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(66)

Issue 6500114: code review 6500114: exp/types/staging: operands, constants, and error handling (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
11 years, 6 months ago by gri
Modified:
11 years, 6 months ago
Reviewers:
CC:
rsc, r, golang-dev
Visibility:
Public.

Description

exp/types/staging: operands, constants, and error handling More pieces of the typechecker code: - Operands are temporary objects representing an expressions's type and value (for constants). An operand is the equivalent of an "attribute" in attribute grammars except that it's not stored but only passed around during type checking. - Constant operations are implemented in const.go. Constants are represented as bool (booleans), int64 and *big.Int (integers), *big.Rat (floats), complex (complex numbers), and string (strings). - Error reporting is consolidated in errors.go. Only the first dozen of lines is new code, the rest of the file contains the exprString and typeString functions formerly in two separate files (which have been removed). This is a replacement CL for 6492101 (which was created without proper use of hg).

Patch Set 1 #

Patch Set 2 : diff -r ffe134f40269 https://go.googlecode.com/hg/ #

Patch Set 3 : diff -r ffe134f40269 https://go.googlecode.com/hg/ #

Patch Set 4 : diff -r ffe134f40269 https://go.googlecode.com/hg/ #

Patch Set 5 : diff -r 56f5a223dcd7 https://code.google.com/p/go #

Patch Set 6 : diff -r e990cf183236 https://code.google.com/p/go #

Patch Set 7 : diff -r 23b89fb47d66 https://code.google.com/p/go #

Total comments: 31

Patch Set 8 : diff -r eb75b492bf41 https://code.google.com/p/go #

Patch Set 9 : diff -r eb75b492bf41 https://code.google.com/p/go #

Total comments: 1

Patch Set 10 : diff -r c70d7dfc3d07 https://code.google.com/p/go #

Patch Set 11 : diff -r c70d7dfc3d07 https://code.google.com/p/go #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1499 lines, -780 lines) Patch
M src/pkg/exp/types/staging/check.go View 1 2 3 4 5 6 7 2 chunks +256 lines, -186 lines 0 comments Download
M src/pkg/exp/types/staging/const.go View 1 2 3 4 5 6 7 1 chunk +591 lines, -277 lines 0 comments Download
A src/pkg/exp/types/staging/errors.go View 1 2 3 4 5 6 1 chunk +298 lines, -0 lines 0 comments Download
R src/pkg/exp/types/staging/exprstring.go View 1 1 chunk +0 lines, -98 lines 0 comments Download
A src/pkg/exp/types/staging/operand.go View 1 2 3 4 5 6 7 1 chunk +201 lines, -0 lines 0 comments Download
M src/pkg/exp/types/staging/predicates.go View 1 2 2 chunks +43 lines, -17 lines 0 comments Download
A src/pkg/exp/types/staging/stubs.go View 1 2 3 4 5 6 7 1 chunk +55 lines, -0 lines 0 comments Download
M src/pkg/exp/types/staging/types.go View 1 2 3 4 5 6 7 3 chunks +7 lines, -6 lines 0 comments Download
R src/pkg/exp/types/staging/typestring.go View 1 1 chunk +0 lines, -148 lines 0 comments Download
M src/pkg/exp/types/staging/universe.go View 1 2 3 4 5 6 7 2 chunks +48 lines, -48 lines 0 comments Download

Messages

Total messages: 5
gri
Hello rsc@golang.org, r@golang.org (cc: golang-dev@googlegroups.com), I'd like you to review this change to https://go.googlecode.com/hg/
11 years, 6 months ago (2012-09-12 04:41:59 UTC) #1
rsc
Code seems fine but please document what functions and methods are intended to do. http://codereview.appspot.com/6500114/diff/10010/src/pkg/exp/types/staging/check.go ...
11 years, 6 months ago (2012-09-17 20:28:46 UTC) #2
gri
PTAL http://codereview.appspot.com/6500114/diff/10010/src/pkg/exp/types/staging/check.go File src/pkg/exp/types/staging/check.go (right): http://codereview.appspot.com/6500114/diff/10010/src/pkg/exp/types/staging/check.go#newcode1 src/pkg/exp/types/staging/check.go:1: // Copyright P011 The Go Authors. All rights ...
11 years, 6 months ago (2012-09-18 23:16:11 UTC) #3
rsc
LGTM http://codereview.appspot.com/6500114/diff/16012/src/pkg/exp/types/staging/operand.go File src/pkg/exp/types/staging/operand.go (right): http://codereview.appspot.com/6500114/diff/16012/src/pkg/exp/types/staging/operand.go#newcode75 src/pkg/exp/types/staging/operand.go:75: fmt.Fprintf(&buf, " of type %s", typeString(x.typ)) Aha. Here ...
11 years, 6 months ago (2012-09-24 15:08:59 UTC) #4
gri
11 years, 6 months ago (2012-09-26 00:38:31 UTC) #5
*** Submitted as http://code.google.com/p/go/source/detail?r=e35106c26e0b ***

exp/types/staging: operands, constants, and error handling

More pieces of the typechecker code:

- Operands are temporary objects representing an expressions's
type and value (for constants). An operand is the equivalent of
an "attribute" in attribute grammars except that it's not stored
but only passed around during type checking.

- Constant operations are implemented in const.go. Constants are
represented as bool (booleans), int64 and *big.Int (integers),
*big.Rat (floats), complex (complex numbers), and string (strings).

- Error reporting is consolidated in errors.go. Only the first
dozen of lines is new code, the rest of the file contains the
exprString and typeString functions formerly in two separate
files (which have been removed).

This is a replacement CL for 6492101 (which was created without
proper use of hg).

R=rsc, r
CC=golang-dev
http://codereview.appspot.com/6500114
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b