Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
go
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
go
Commits
3cd10e3a
Commit
3cd10e3a
authored
Jan 04, 2011
by
Russ Cox
Browse files
Options
Browse Files
Download
Plain Diff
merge tree
parents
9214016b
4e5a5959
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
21 additions
and
1 deletion
+21
-1
src/cmd/gc/walk.c
src/cmd/gc/walk.c
+3
-1
test/fixedbugs/bug315.go
test/fixedbugs/bug315.go
+18
-0
No files found.
src/cmd/gc/walk.c
View file @
3cd10e3a
...
...
@@ -975,13 +975,15 @@ walkexpr(Node **np, NodeList **init)
* on 386, rewrite float ops into l = l op r.
* everywhere, rewrite map ops into l = l op r.
* everywhere, rewrite string += into l = l op r.
* everywhere, rewrite complex /= into l = l op r.
* TODO(rsc): Maybe this rewrite should be done always?
*/
et
=
n
->
left
->
type
->
etype
;
if
((
widthptr
==
4
&&
(
et
==
TUINT64
||
et
==
TINT64
))
||
(
thechar
==
'8'
&&
isfloat
[
et
])
||
l
->
op
==
OINDEXMAP
||
et
==
TSTRING
)
{
et
==
TSTRING
||
(
iscomplex
[
et
]
&&
n
->
etype
==
ODIV
))
{
l
=
safeexpr
(
n
->
left
,
init
);
a
=
l
;
if
(
a
->
op
==
OINDEXMAP
)
{
...
...
test/fixedbugs/bug315.go
0 → 100644
View file @
3cd10e3a
// $G $D/$F.go || echo BUG: bug315
// Copyright 2010 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
// Issue 1368.
package
main
func
main
()
{
a
:=
cmplx
(
2
,
2
)
a
/=
2
}
/*
bug315.go:13: internal compiler error: optoas: no entry DIV-complex
*/
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment