Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
G
golang
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
go
golang
Commits
a3cdd2e8
Commit
a3cdd2e8
authored
Oct 25, 2008
by
Ken Thompson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug
R=r OCL=17853 CL=17853
parent
6d3d56d5
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
subr.c
src/cmd/gc/subr.c
+4
-0
No files found.
src/cmd/gc/subr.c
View file @
a3cdd2e8
...
@@ -2586,12 +2586,15 @@ expandmeth(Sym *s, Type *t)
...
@@ -2586,12 +2586,15 @@ expandmeth(Sym *s, Type *t)
if
(
t
==
T
)
if
(
t
==
T
)
return
;
return
;
//print("s=%S t=%lT\n", s, t);
// generate all reachable methods
// generate all reachable methods
slist
=
nil
;
slist
=
nil
;
expand1
(
t
,
nelem
(
dotlist
)
-
1
);
expand1
(
t
,
nelem
(
dotlist
)
-
1
);
// check each method to be uniquely reachable
// check each method to be uniquely reachable
for
(
sl
=
slist
;
sl
!=
nil
;
sl
=
sl
->
link
)
{
for
(
sl
=
slist
;
sl
!=
nil
;
sl
=
sl
->
link
)
{
sl
->
field
->
sym
->
uniq
=
0
;
for
(
d
=
0
;
d
<
nelem
(
dotlist
);
d
++
)
{
for
(
d
=
0
;
d
<
nelem
(
dotlist
);
d
++
)
{
c
=
adddot1
(
sl
->
field
->
sym
,
t
,
d
);
c
=
adddot1
(
sl
->
field
->
sym
,
t
,
d
);
if
(
c
==
0
)
if
(
c
==
0
)
...
@@ -2604,6 +2607,7 @@ expandmeth(Sym *s, Type *t)
...
@@ -2604,6 +2607,7 @@ expandmeth(Sym *s, Type *t)
for
(
sl
=
slist
;
sl
!=
nil
;
sl
=
sl
->
link
)
{
for
(
sl
=
slist
;
sl
!=
nil
;
sl
=
sl
->
link
)
{
if
(
sl
->
good
)
{
if
(
sl
->
good
)
{
//print(" %lT\n", sl->field);
// add it to the base type method list
// add it to the base type method list
f
=
typ
(
TFIELD
);
f
=
typ
(
TFIELD
);
*
f
=
*
sl
->
field
;
*
f
=
*
sl
->
field
;
...
...
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