1
0
mirror of https://github.com/golang/go synced 2024-10-04 11:21:21 -06:00
Commit Graph

1561 Commits

Author SHA1 Message Date
Rob Pike
b1d37b74d9 reflect.PtrValue.SetSub() to set pointers
R=rsc
OCL=19101
CL=19101
2008-11-12 14:19:39 -08:00
Rob Pike
2f4d35ffb9 converting uint bits back into floats
R=rsc
DELTA=32  (32 added, 0 deleted, 0 changed)
OCL=19084
CL=19091
2008-11-12 11:51:34 -08:00
Robert Griesemer
2727abe4fc - lowercased package name (Bignum -> bignum)
- implemented some missing functionality (and, or, xor of positive ints)

R=r
OCL=19087
CL=19087
2008-11-12 11:00:11 -08:00
Ian Lance Taylor
9c9cc2c9d8 Recognize gccgo error messages. This uses GCCGO_ERROR, which
is recognized by the gccgo testsuite but is ignored by the
errchk script used with 6g.

method1.go:7:1: error: redefinition of 'M': parameter types changed
method1.go:6:1: note: previous definition of 'M' was here
method1.go:10:1: error: redefinition of 'f': parameter types changed
method1.go:9:1: note: previous definition of 'f' was here
method1.go:13:1: error: redefinition of 'g': parameter names changed
method1.go:12:1: note: previous definition of 'g' was here

R=rsc
DELTA=5  (0 added, 0 deleted, 5 changed)
OCL=18962
CL=19058
2008-11-11 18:18:34 -08:00
Ian Lance Taylor
a957ceec35 The scope rules have been changed to say that labels live in a
separate per-function namespace.

R=gri
DELTA=24  (8 added, 16 deleted, 0 changed)
OCL=19006
CL=19057
2008-11-11 18:17:54 -08:00
Ken Thompson
902a4d5f29 6c bug with large constants
R=r
OCL=19056
CL=19056
2008-11-11 18:15:36 -08:00
Rob Pike
6ee7fe5808 Implement a "full reader" wrapper for io.Read, guaranteeing that
either the buffer is full, zero bytes were read, or an error is returned.

R=rsc
DELTA=44  (42 added, 0 deleted, 2 changed)
OCL=19027
CL=19047
2008-11-11 17:28:36 -08:00
Russ Cox
b682f924d7 don't try interface/structure conversion until
last resort, because it assumes every call is a
real use of the conversion.

R=ken
OCL=19026
CL=19026
2008-11-11 15:55:32 -08:00
Russ Cox
792145723e width fixes.
* check for uncomputed struct offsets
* distinguish function structs from ordinary structs
* make sure function structs are not examined in isolation

R=ken
OCL=19005
CL=19005
2008-11-11 13:46:55 -08:00
Ian Lance Taylor
07c54425c0 Remove useless "Trace/breakpoint trap" lines using the format
that is generated on Goobuntu.

R=r,rsc
DELTA=2  (1 added, 0 deleted, 1 changed)
OCL=18973
CL=18976
2008-11-11 10:01:51 -08:00
Rob Pike
0e544fa0e3 fix error-handling bug.
add newline after stack traces.

R=rsc
DELTA=3  (2 added, 1 deleted, 0 changed)
OCL=18945
CL=18953
2008-11-10 18:13:20 -08:00
Robert Griesemer
2a58e7d7a0 more work on elastic tabs:
- new code enabled, but no comments printed yet (so the effect
  of the elastic tabs is not seen yet)

TBR=r
DELTA=200  (93 added, 69 deleted, 38 changed)
OCL=18951
CL=18951
2008-11-10 17:56:46 -08:00
Russ Cox
600ee088b6 * accept all NaNs, not just the one sys.NaN() returns.
* use union, not cast, to convert between uint64 and float64,
  to avoid possible problems with gcc in future.

R=r
DELTA=75  (39 added, 15 deleted, 21 changed)
OCL=18926
CL=18926
2008-11-10 15:17:56 -08:00
Rob Pike
203a17c6ec update tests
R=gri
DELTA=28  (12 added, 14 deleted, 2 changed)
OCL=18923
CL=18923
2008-11-10 14:59:15 -08:00
Russ Cox
e8766354a4 handle Inf, NaN in float print
R=r
DELTA=48  (23 added, 14 deleted, 11 changed)
OCL=18707
CL=18922
2008-11-10 14:54:10 -08:00
Rob Pike
842e1a9aa7 Add a cache to avoid unnecessary parsing of type strings when constructing values
R=rsc
DELTA=12  (9 added, 0 deleted, 3 changed)
OCL=18916
CL=18921
2008-11-10 14:53:40 -08:00
Rob Pike
10137e7f1d fix start/stop bug in prof.
also only time-limit if a value is provided.

R=rsc
DELTA=9  (4 added, 2 deleted, 3 changed)
OCL=18917
CL=18920
2008-11-10 14:53:32 -08:00
Rob Pike
091fb779a1 Protocol buffer encoding.
R=rsc
DELTA=1075  (1028 added, 31 deleted, 16 changed)
OCL=18865
CL=18918
2008-11-10 14:47:28 -08:00
Robert Griesemer
176e256b26 Added missing Set method for Vector
BUG=1474670
TBR=r
DELTA=6  (6 added, 0 deleted, 0 changed)
OCL=18839
CL=18843
2008-11-07 18:31:50 -08:00
Robert Griesemer
a3b4a3c29d - steps towards "flexible tab stops" simulation in pretty
printing output
- not yet enabled

R=r
OCL=18842
CL=18842
2008-11-07 18:30:58 -08:00
Rob Pike
4328d44254 wrong system call number for stat
TBR=rsc
OCL=18833
CL=18833
2008-11-07 16:17:42 -08:00
Ken Thompson
79f5697b02 byte multiply
R=r
OCL=18830
CL=18830
2008-11-07 16:05:17 -08:00
Ken Thompson
dc78c64f23 byte multiply
R=r
OCL=18807
CL=18807
2008-11-07 14:20:32 -08:00
Robert Griesemer
434c6052d8 - language to define type equality rigorously
- language for type guards
- fixed language for break statements

Also: Removed uses of "we" and replaced by impersonal language.
Minor cosmetic changes.

DELTA=237  (160 added, 34 deleted, 43 changed)
OCL=18620
CL=18800
2008-11-07 13:34:37 -08:00
Ian Lance Taylor
f8d7f5bd81 Don't use a type guard with a type which is not an interface.
R=r,gri
DELTA=2  (0 added, 0 deleted, 2 changed)
OCL=18781
CL=18785
2008-11-07 11:44:15 -08:00
Ian Lance Taylor
d5ba668edd Test case for evaluation order of select statement.
R=r
DELTA=47  (47 added, 0 deleted, 0 changed)
OCL=18581
CL=18748
2008-11-06 22:27:32 -08:00
Ken Thompson
9b827cf9a0 bug in select default
R=r
OCL=18741
CL=18741
2008-11-06 17:50:28 -08:00
Ian Lance Taylor
9c7374d71b Erroneous test case. The break statement should break out of
a select clause.

R=ken
DELTA=20  (0 added, 20 deleted, 0 changed)
OCL=18731
CL=18739
2008-11-06 17:39:48 -08:00
Robert Griesemer
483e031525 - binomial implementation (fixing broken build)
R=r
OCL=18738
CL=18738
2008-11-06 17:29:07 -08:00
Rob Pike
175dd773e6 simpleminded ascii to floating point conversion
R=rsc
DELTA=111  (107 added, 0 deleted, 4 changed)
OCL=18720
CL=18725
2008-11-06 16:32:28 -08:00
Rob Pike
335a5236e7 add sys.float32bits, sys.float64bits
R=rsc
DELTA=21  (21 added, 0 deleted, 0 changed)
OCL=18709
CL=18718
2008-11-06 15:48:36 -08:00
Ian Lance Taylor
ce15158502 Test that a break statement inside a select statement breaks
out of the enclosing loop.

R=ken
DELTA=20  (20 added, 0 deleted, 0 changed)
OCL=18686
CL=18714
2008-11-06 15:24:10 -08:00
Russ Cox
ec81145565 s/gins/gbranch/
R=ken
OCL=18713
CL=18713
2008-11-06 15:05:19 -08:00
Russ Cox
0eda21a2fd change minimum sethi/ullman number to 1
to distinguish not computed (0) vs trivial (1).

add missing ullmancalc on function args.

R=ken
OCL=18711
CL=18711
2008-11-06 14:50:58 -08:00
Robert Griesemer
ce164403da A recreational programming exercise:
Multiplication of a Hilbert matrix with its inverse using
Bignum.Rationals as a test case for rational arithmetic.

R=r
OCL=18706
CL=18706
2008-11-06 14:23:49 -08:00
Russ Cox
9906bfc7bb 6g ninit fixes - fixes the two test cases
i isolated last night.  does not fix rob's
interface-smashing bug.

R=ken
OCL=18698
CL=18698
2008-11-06 13:31:13 -08:00
Robert Griesemer
66c6b13b03 - implemented String() and Format functionality in Bignum
- added a test

R=r
OCL=18687
CL=18687
2008-11-06 12:13:52 -08:00
Robert Griesemer
3a2c0a9615 - fixes to sprintf (by rob)
R=r
OCL=18685
CL=18685
2008-11-06 11:56:08 -08:00
Rob Pike
91212bd1ad If a value implements String(), use that in fmt.print (not fmt.printf)
R=rsc
DELTA=13  (9 added, 0 deleted, 4 changed)
OCL=18682
CL=18684
2008-11-06 11:38:44 -08:00
Rob Pike
f15dfa7802 Polymorphic printing.
R=rsc
DELTA=100  (70 added, 10 deleted, 20 changed)
OCL=18663
CL=18669
2008-11-06 10:40:57 -08:00
Ken Thompson
79fbbe37a7 select default
R=r
OCL=18646
CL=18646
2008-11-05 21:50:28 -08:00
Russ Cox
a6af484328 more runtime support for chan select default
R=ken
OCL=18630
CL=18630
2008-11-05 18:04:24 -08:00
Russ Cox
b69e80d8dd runtime support for default in select.
assumes cas->send == 2 for default case.

R=ken
OCL=18628
CL=18628
2008-11-05 17:57:18 -08:00
Russ Cox
d6a7cefd1e allow any type at all in sys.unreflect;
accomodate empty type table in 6l.

R=r
DELTA=10  (2 added, 8 deleted, 0 changed)
OCL=18601
CL=18605
2008-11-05 16:09:12 -08:00
Robert Griesemer
b3c983f3a0 - fixed typo in parser.go
- re-enabled bug118.go for pretty

R=r
OCL=18604
CL=18604
2008-11-05 16:05:36 -08:00
Russ Cox
553c98dca4 fix renamed-package bug in exported names:
always show original name

R=ken
OCL=18603
CL=18603
2008-11-05 15:59:34 -08:00
Robert Griesemer
11a3f759fd - temporarily excluding bug118.go, causing pretty trouble
R=r
OCL=18602
CL=18602
2008-11-05 15:55:51 -08:00
Ken Thompson
83a798513c more on t,ok = I.(T)
R=r
OCL=18599
CL=18599
2008-11-05 15:33:01 -08:00
Ian Lance Taylor
48d111f0b9 6g dumps core on this input file.
R=ken,rsc
DELTA=14  (14 added, 0 deleted, 0 changed)
OCL=18555
CL=18598
2008-11-05 15:27:40 -08:00
Ken Thompson
a8b56a73a4 T,ok = I.(T)
R=r
OCL=18580
CL=18582
2008-11-05 14:27:07 -08:00