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

Delta Between Two Patch Sets: src/pkg/runtime/iface.c

Issue 5490053: code review 5490053: runtime: make more build-friendly (Closed)
Left Patch Set: diff -r 4bd43e05039c https://go.googlecode.com/hg/ Created 13 years, 3 months ago
Right Patch Set: diff -r 046739c8299b https://go.googlecode.com/hg/ Created 13 years, 3 months ago
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
Right: Side by side diff | Download
« no previous file with change/comment | « src/pkg/runtime/defs_windows_amd64.h ('k') | src/pkg/runtime/malloc.goc » ('j') | no next file with change/comment »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
LEFTRIGHT
(no file at all)
1 // Copyright 2009 The Go Authors. All rights reserved. 1 // Copyright 2009 The Go Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style 2 // Use of this source code is governed by a BSD-style
3 // license that can be found in the LICENSE file. 3 // license that can be found in the LICENSE file.
4 4
5 #include "runtime.h" 5 #include "runtime.h"
6 #include "arch.h" 6 #include "arch_GOARCH.h"
7 #include "type.h" 7 #include "type.h"
8 #include "malloc.h" 8 #include "malloc.h"
9 9
10 enum· 10 enum·
11 { 11 {
12 // If an empty interface has these bits set in its type 12 // If an empty interface has these bits set in its type
13 // pointer, it was copied from a reflect.Value and is 13 // pointer, it was copied from a reflect.Value and is
14 // not a valid empty interface. 14 // not a valid empty interface.
15 reflectFlags = 3, 15 reflectFlags = 3,
16 }; 16 };
(...skipping 774 matching lines...) Expand 10 before | Expand all | Expand 10 after
791 // type structure sits before the data pointer. 791 // type structure sits before the data pointer.
792 t = (Type*)((Eface*)typ.data-1); 792 t = (Type*)((Eface*)typ.data-1);
793 ········ 793 ········
794 size = n*t->size; 794 size = n*t->size;
795 if(t->kind&KindNoPointers) 795 if(t->kind&KindNoPointers)
796 ret = runtime·mallocgc(size, FlagNoPointers, 1, 1); 796 ret = runtime·mallocgc(size, FlagNoPointers, 1, 1);
797 else 797 else
798 ret = runtime·mal(size); 798 ret = runtime·mal(size);
799 FLUSH(&ret); 799 FLUSH(&ret);
800 } 800 }
LEFTRIGHT

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