2,626 matches across 25 files for TODO lang:Go
snippet_mode: auto · sorted by relevance
108 rangeLitGen int
109
110▶ // TODO(mdempsky): The state below is all specific to reading
111 // function bodies. It probably makes sense to split it out
112 // separately so that it doesn't take up space in every reader
· · ·
554 // to "any".
555
556▶ // TODO(mdempsky): Restore consistency check to make sure folding to
557 // "any" is safe. This is unfortunately tricky, because a pure
558 // interface can reference impure interfaces too, including
· · ·
829 setType(name, shapeSig(name.Func, r.dict))
830 } else {
831▶ todoDicts = append(todoDicts, func() {
832 r.dict.shapedObj = pr.objIdx(idx, implicits, explicits, true).(*ir.Name)
833 })
· · ·
856
857 if r.hasTypeParams() && !r.dict.shaped {
858▶ todoDicts = append(todoDicts, func() {
859 r.dict.shapedObj = pr.objIdx(idx, implicits, explicits, true).(*ir.Name)
860 })
· · ·
990 // Otherwise, we simply use the type's underlying type as its shape.
991 //
992▶ // TODO(mdempsky): It should be possible to do much more aggressive
993 // shaping still; e.g., collapsing all pointer-shaped types into a
994 // common type, collapsing scalars of the same size/alignment into a
+ 46 more matches in this file
248 return abi0
249 case obj.ABIInternal:
250▶ // TODO(austin): Clean up the nomenclature here.
251 // It's not clear that "abi1" is ABIInternal.
252 return abi1
· · ·
258 a := abi0
259 if fn != nil {
260▶ if fn.Pragma&ir.RegisterParams != 0 { // TODO(register args) remove after register abi is working
261 a = abi1
262 }
· · ·
393 }
394 htmlWriter = ssahtml.NewHTMLWriter(ssaDF, s.f, ssaDumpCFG, compiler.Passes())
395▶ // TODO: generate and print a mapping from nodes to values and blocks
396 dumpSourcesColumn(htmlWriter, fn)
397 htmlWriter.WriteAST("AST", astBuf)
· · ·
413 // preceding the deferreturn/ret code that we don't track correctly.
414 //
415▶ // TODO this restriction can be removed given adjusted offset in computeDeferReturn in cmd/link/internal/ld/pcln.go
416 s.hasOpenDefers = false
417 }
· · ·
442 }
443
444▶ s.sp = s.entryNewValue0(ssaop.OpSP, types.Types[types.TUINTPTR]) // TODO: use generic pointer type (unsafe.Pointer?) instead
445 s.sb = s.entryNewValue0(ssaop.OpSB, types.Types[types.TUINTPTR])
446
+ 46 more matches in this file
82// x is now a spilled value and a restore must appear before its first use.
83
84▶// TODO
85
86// Use an affinity graph to mark two values which should use the
· · ·
110// of x3 not dominated by the definition of x3, and the CX->BX copy
111// will have no use (so don't run deadcode after regalloc!).
112▶// TODO: maybe we should introduce these extra phis?
113
114package ssacompile
· · ·
297type endReg struct {
298 r ssaop.Register
299▶ v *ssa.Value // pre-regalloc value held in this register (TODO: can we use ID here?)
300 c *ssa.Value // cached version of the value
301}
· · ·
407 // Pick a value to spill. Spill the value with the
408 // farthest-in-the-future use.
409▶ // TODO: Prefer registers with already spilled Values?
410 // TODO: Modify preference using affinity graph.
411 // TODO: if a single value is in multiple registers, spill one of them
· · ·
410▶ // TODO: Modify preference using affinity graph.
411 // TODO: if a single value is in multiple registers, spill one of them
412 // before spilling a value in just a single register.
+ 17 more matches in this file
175
176 // For each slice s, a map from s to a len(s)/cap(s) value (if any)
177▶ // TODO: check if there are cases that matter where we have
178 // more than one len(s) for a slice. We could keep a list if necessary.
179 lens map[ssa.ID]*ssa.Value
· · ·
304 // the posets will not notice.
305 if ft.recurseCheck[v.ID] {
306▶ // This should only happen for unsatisfiable cases. TODO: check
307 return
308 }
· · ·
317 ft.limits[v.ID] = lim
318 if v.Block.Func.Pass.Debug > 2 {
319▶ // TODO: pos is probably wrong. This is the position where v is defined,
320 // not the position where we learned the fact about it (which was
321 // probably some subsequent compare+branch).
· · ·
430 r ^= lt | gt | eq
431 }
432▶ // TODO: v.Block is wrong?
433 addRestrictions(v.Block, ft, d, v.Args[0], v.Args[1], r)
434 }
· · ·
466 }
467 ft.update(v.Block, v.Args[0], v.Args[1], unsigned, r)
468▶ // TODO: v.Block is wrong here
469 }
470 }
+ 12 more matches in this file
56// function body reading code.
57
58▶// TODO(mdempsky): Add an importer for Unified IR to the x/tools repo,
59// and better document the file format boundary between public and
60// private data.
· · ·
182 sig *types2.Signature
183
184▶ // TODO(mdempsky): We should be able to prune localsIdx whenever a
185 // scope closes, and then maybe we can just use the same map for
186 // storing the TypeParams too (as their TypeName instead).
· · ·
390 pos := p.Pos()
391
392▶ // TODO(mdempsky): Track down the remaining cases here and fix them.
393 if !w.Bool(pos.IsKnown()) {
394 return
· · ·
395 }
396
397▶ // TODO(mdempsky): Delta encoding.
398 w.posBase(pos.Base())
399 w.Uint(pos.Line())
· · ·
459 w.String("unsafe")
460 default:
461▶ // TODO(mdempsky): Write out pkg.Path() for curpkg too.
462 var path string
463 if pkg != w.p.curpkg {
+ 19 more matches in this file
207 // 48 bits because this uses too much address space for older
208 // iOS versions.
209▶ // TODO(mknyszek): Once iOS <14 is deprecated, promote ios/arm64
210 // to a 48-bit address space like every other arm64 platform.
211 //
· · ·
784 // Failed. Discard this hint and try the next.
785 //
786▶ // TODO: This would be cleaner if sysReserve could be
787 // told to only return the requested address. In
788 // particular, this is already how Windows behaves, so
· · ·
1043// enabled, and none of the memory sanitizers should be enabled. We allow the race detector,
1044// in contrast to sizeSpecializedMallocEnabled.
1045▶// TODO(thepudds): it would be nice to check Valgrind integration, though there are some hints
1046// there might not be any canned tests in tree for Go's integration with Valgrind.
1047const runtimeFreegcEnabled = goexperiment.RuntimeFreegc && !asanenabled && !msanenabled && !valgrindenabled
· · ·
1257 // value is aligned to 8 bytes and does not cause a fault on
1258 // atomic access. See issue 37262.
1259▶ // TODO(mknyszek): Remove this workaround if/when issue 36606
1260 // is resolved.
1261 off = alignUp(off, 8)
· · ·
1323 // will update the mem profile on the "free" side.
1324 //
1325▶ // TODO(mknyszek): We should really count the header as part
1326 // of gc_sys or something. The code below just pretends it is
1327 // internal fragmentation and matches the GC's accounting by
+ 21 more matches in this file
143 var err error
144 if a.Actor != nil && (a.Failed == nil || a.IgnoreFail) {
145▶ // TODO(matloob): Better action descriptions
146 desc := "Executing action (" + a.Mode
147 if a.Package != nil {
· · ·
318 }
319
320▶ // TODO(rsc): Convince compiler team not to add more magic environment variables,
321 // or perhaps restrict the environment variables passed to subprocesses.
322 // Because these are clumsy, undocumented special-case hacks
· · ·
352
353 // Input files.
354▶ // TODO(matloob): once the build action depends on the cgo actions, we can
355 // use those actions' outputs instead of the file names and hashes.
356 inputFiles := str.StringList(
· · ·
405 // (https://go.dev/issue/47257) and no longer support GOROOT_FINAL
406 // (https://go.dev/issue/62047).
407▶ // TODO(bcmills): Figure out whether this behavior is still useful.
408 //
409 // b.WorkDir is always either trimmed or rewritten to
· · ·
451 }
452 }
453▶ // TODO(rsc): Should we include the SWIG version?
454 }
455}
+ 14 more matches in this file
3// license that can be found in the LICENSE file.
4
5▶// TODO: turn off the serve goroutine when idle, so
6// an idle conn only has the readFrames goroutine active. (which could
7// also be optimized probably to pin less memory in crypto/tls). This
· · ·
15// returns.
16
17▶// TODO (maybe): add a mechanism for Handlers to going into
18// half-closed-local mode (rw.(io.Closer) test?) but not exit their
19// handler, and continue to be able to read from the
· · ·
59 firstSettingsTimeout = 2 * time.Second // should be in-flight with preface anyway
60 handlerChunkWriteSize = 4 << 10
61▶ defaultMaxStreams = 250 // TODO: make this 100 as the GFE seems to?
62
63 // maxQueuedControlFrames is the maximum number of control frames like
· · ·
360 // addresses during development.
361 //
362▶ // TODO: optionally enforce? Or enforce at the time we receive
363 // a new request, and verify the ServerName matches the :authority?
364 // But that precludes proxy situations, perhaps.
· · ·
600// errno returns v's underlying uintptr, else 0.
601//
602▶// TODO: remove this helper function once http2 can use build
603// tags. See comment in isClosedConnError.
604func errno(v error) uintptr {
+ 13 more matches in this file
131 case _Name,
132 _Break, _Continue, _Fallthrough, _Return,
133▶ /*_Inc, _Dec,*/ _Rparen, _Rbrack, _Rbrace: // TODO(gri) fix this
134 return true
135 }
· · ·
137}
138
139▶// TODO(gri) provide table of []byte values for all tokens to avoid repeated string conversion
140
141func (p *printer) addWhitespace(kind ctrlSymbol, text string) {
· · ·
146 case newline:
147 p.lastTok = 0
148▶ // TODO(gri) do we need to handle /*-style comments containing newlines here?
149 }
150}
· · ·
177 // }
178 // case eolComment:
179▶ // // TODO(gri) act depending on sawNewline
180 default:
181 panic("unreachable")
· · ·
220 // prev = comment
221 // }
222▶ // // TODO(gri) should check that line comments are always followed by newline
223 default:
224 panic("unreachable")
+ 7 more matches in this file
328 cs.closeReqBodyLocked()
329 }
330▶ // TODO(dneil): Clean up tests where cs.cc.cond is nil.
331 if cs.cc.cond != nil {
332 // Wake up writeRequestBody if it is waiting on flow control.
· · ·
672 cc.flow.add(int32(initialWindowSize))
673
674▶ // TODO: adjust this writer size to account for frame size +
675 // MTU + crypto/tls record padding.
676 cc.bw = bufio.NewWriter(stickyErrWriter{
· · ·
973 cc.closedOnIdle = true
974 nextID := cc.nextStreamID
975▶ // TODO: do clients send GOAWAY too? maybe? Just Close:
976 cc.mu.Unlock()
977
· · ·
1558 }
1559
1560▶ // TODO: write h12Compare test showing whether
1561 // Request.Body is closed by the Transport,
1562 // and in multiple cases: server replies <=299 and >299
· · ·
1842 err = cc.fr.WriteData(cs.ID, sentEnd, data)
1843 if err == nil {
1844▶ // TODO(bradfitz): this flush is for latency, not bandwidth.
1845 // Most requests won't need this. Make this opt-in or
1846 // opt-out? Use some heuristic on the body type? Nagel-like
+ 11 more matches in this file
790
791func (p *parser) parseParamDecl(name *ast.Ident, typeSetsOK bool) (f field) {
792▶ // TODO(rFindley) refactor to be more similar to paramDeclOrNil in the syntax
793 // package
794 if p.trace {
· · ·
858
859 default:
860▶ // TODO(rfindley): this is incorrect in the case of type parameter lists
861 // (should be "']'" in that case)
862 p.errorExpected(p.pos, "')'")
· · ·
1020 }
1021 // use T instead of invalid ...T
1022▶ // TODO(gri) would like to use `f.typ = t.Elt` but that causes problems
1023 // with the resolver in cases of reuse of the same identifier
1024 f.typ = &ast.BadExpr{From: t.Pos(), To: t.End()}
· · ·
1152 p.error(lbrack, "interface method must have no type parameters")
1153
1154▶ // TODO(rfindley) refactor to share code with parseFuncType.
1155 params := p.parseParameters(false)
1156 results := p.parseParameters(true)
· · ·
1163 } else {
1164 // embedded instantiated type
1165▶ // TODO(rfindley) should resolve all identifiers in x.
1166 list := []ast.Expr{x}
1167 if p.atComma("type argument list", token.RBRACK) {
+ 6 more matches in this file
36// printed.
37//
38▶// TODO(gri): linebreak may add too many lines if the next statement at "line"
39// is preceded by comments because the computation of n assumes
40// the current position before the comment and the target position
· · ·
119// expressions.
120//
121▶// TODO(gri) Consider rewriting this to be independent of []ast.Expr
122// so that we can use the algorithm for any kind of list
123//
· · ·
196 // in general, use the entire node size to make the decision; for
197 // key:value expressions, use the key size.
198▶ // TODO(gri) for a better result, should probably incorporate both
199 // the key and the node size into the decision process
200 useFF := true
· · ·
608 if i > 0 {
609 // don't do a line break (min == 0) if we are printing a list of types
610▶ // TODO(gri) this doesn't work quite right if the list of types is
611 // spread across multiple lines
612 min := 1
· · ·
858 p.print(x.Op)
859 if x.Op == token.RANGE {
860▶ // TODO(gri) Remove this code if it cannot be reached.
861 p.print(blank)
862 }
+ 5 more matches in this file
38// Variables set by other packages.
39//
40▶// TODO(#40775): See if these can be plumbed as explicit parameters.
41var (
42 // ExplicitWriteGoMod prevents LoadPackages, ListModules, and other functions
· · ·
257 // Special case: we are outside a module, like 'go run x.go'.
258 // Assume the local Go version.
259▶ // TODO(#49228): Clean this up; see loadModFile.
260 return gover.Local()
261 }
· · ·
732
733func modFilePath(modRoot string) string {
734▶ // TODO(matloob): This seems incompatible with workspaces
735 // (unless the user's intention is to replace all workspace modules' modfiles?).
736 // Should we produce an error in workspace mode if cfg.ModFile is set?
· · ·
907
908 // Clean up and annotate directories.
909▶ // TODO(matloob): update x/mod to actually add module paths.
910 for moddir, absmodroot := range missingModulePaths {
911 _, f, err := ReadModFile(filepath.Join(absmodroot, "go.mod"), nil)
· · ·
983 }
984 if len(ld.modRoots) == 0 {
985▶ // TODO(#49228): Instead of creating a fake module with an empty modroot,
986 // make MainModules.Len() == 0 mean that we're in module mode but not inside
987 // any module.
+ 6 more matches in this file
63var (
64 // List of all hot callee nodes.
65▶ // TODO(prattmic): Make this non-global.
66 candHotCalleeMap = make(map[*pgoir.IRNode]struct{})
67
· · ·
70
71 // List of all hot call sites. CallSiteInfo.Callee is always nil.
72▶ // TODO(prattmic): Make this non-global.
73 candHotEdgeMap = make(map[pgoir.CallSiteInfo]struct{})
74
· · ·
382 // alive information is lost during inlining.
383 //
384▶ // TODO(prattmic): This is handled on calls during escape analysis,
385 // which is after inlining. Move prior to inlining so the keep-alive is
386 // maintained after inlining.
· · ·
647 // will miss those.
648 //
649▶ // TODO: in the case of a single-call closure, the inlining budget here is potentially much, much larger.
650 //
651 v.budget -= callee.Inl.Cost
· · ·
683
684 case ir.ORECOVER:
685▶ // TODO: maybe we could allow inlining of recover() now?
686 v.reason = "call to recover"
687 return true
+ 5 more matches in this file
294 }
295 } else {
296▶ // TODO(mdempsky): We should be able to share these too (except
297 // maybe when dynamic linking).
298 sname = fmt.Sprintf("%s%s.%d", sname, types.LocalPkg.Prefix, dnameCount)
· · ·
718 }
719
720▶ // TODO(mdempsky): Investigate whether this still happens.
721 // If we know we don't need to emit code for a type,
722 // we should have a link-symbol index for it.
· · ·
723▶ // See also TODO in NeedEmit.
724 return lsym
725 }
· · ·
775 case types.TPTR:
776 rt = rttype.PtrType
777▶ // TODO: use rttype.Type for Elem() is ANY?
778 case types.TSTRUCT:
779 rt = rttype.StructType
· · ·
1014// create a dummy itab with zeroed-out method entries.
1015func writeITab(lsym *obj.LSym, typ, iface *types.Type, allowNonImplement bool) {
1016▶ // TODO(mdempsky): Fix methodWrapper, geneq, and genhash (and maybe
1017 // others) to stop clobbering these.
1018 oldpos, oldfn := base.Pos, ir.CurFunc
+ 6 more matches in this file
594 // Rename type parameters for cases like f(g, g); this gives each
595 // generic function argument a unique type identity (go.dev/issues/59956).
596▶ // TODO(gri) Consider only doing this if a function argument appears
597 // multiple times, which is rare (possible optimization).
598 atparams, tmp := check.renameTParams(call.Pos(), asig.TypeParams().list(), asig)
· · ·
627 targs = check.infer(call, tparams, targs, sigParams, args, false, err)
628 if targs == nil {
629▶ // TODO(gri) If infer inferred the first targs[:n], consider instantiating
630 // the call signature for better error messages/gopls behavior.
631 // Perhaps instantiate as much as we can, also for arguments.
· · ·
657 k := j + asig.TypeParams().Len()
658 // targs[j:k] are the inferred type arguments for asig
659▶ arg.typ_ = check.instantiateSignature(call.Pos(), arg.expr, asig, targs[j:k], nil) // TODO(gri) provide xlist if possible (partial instantiations)
660 check.record(arg) // record here because we didn't use the usual expr evaluators
661 j = k
· · ·
835
836 if index != nil {
837▶ // TODO(gri) should provide actual type where the conflict happens
838 check.errorf(e.Sel, AmbiguousSelector, "ambiguous selector %s.%s", x.expr, sel)
839 goto Error
· · ·
880 check.objDecl(obj) // ensure fully set-up signature
881 check.addDeclDep(obj)
882▶ // TODO(mark): Assert that sig.rparams is nil here?
883
884 if x.mode() == typexpr {
+ 6 more matches in this file
56}
57
58▶// TODO: Doc. Returns Values with Def domains.
59func loadXED(xedPath string) []*unify.Value {
60 // TODO: Obviously a bunch more to do here.
· · ·
60▶ // TODO: Obviously a bunch more to do here.
61
62 db, err := xeddata.NewDatabase(xedPath)
· · ·
272// operandAction defines whether this operand is read and/or written.
273//
274▶// TODO: Should this live in [xeddata.Operand]?
275type operandAction struct {
276 r bool // Read
· · ·
440 }
441
442▶ // TODO: See xed_decoded_inst_operand_action. This might need to be more
443 // complicated.
444 action, ok := actionEncoding[op.Action]
· · ·
545 }
546
547▶ // TODO: BASE and SEG
548 return nil, fmt.Errorf("unknown operand LHS %q in %q", lhs, operand)
549}
+ 6 more matches in this file
40type Builder struct {
41 WorkDir string // the temporary work directory (ends in filepath.Separator)
42▶ getVendorDir func() string // TODO(jitsu): remove this after we eliminate global module state
43 actionCache map[cacheKey]*Action // a cache of already-constructed actions
44 flagCache map[[2]string]bool // a cache of supported compiler flags
· · ·
242 }
243 if a.Package != nil {
244▶ // TODO(rsc): Make this a unique key for a.Package somehow.
245 a.json.Package = a.Package.ImportPath
246 }
· · ·
436// cacheAction looks up {mode, p} in the cache and returns the resulting action.
437// If the cache has no such action, f() is recorded and returned.
438▶// TODO(rsc): Change the second key from *load.Package to interface{},
439// to make the caching in linkShared less awkward?
440func (b *Builder) cacheAction(mode string, p *load.Package, f func() *Action) *Action {
· · ·
990 // Use breadth-first search to find rebuilt-for-test packages
991 // before the standard ones.
992▶ // TODO(rsc): Eliminate the standard ones from the action graph,
993 // which will require doing a little bit more rebuilding.
994 workq := []*Action{a1}
· · ·
1000 a1 := workq[i]
1001 for _, a2 := range a1.Deps {
1002▶ // TODO(rsc): Find a better discriminator than the Mode strings, once the dust settles.
1003 if a2.Package == nil || (a2.Mode != "build-install" && a2.Mode != "build") || haveDep[a2.Package.ImportPath] {
1004 continue
+ 7 more matches in this file
68 // Queue of locations to walk. Has enough room for b.allLocs
69 // plus b.heapLoc, b.mutatorLoc, b.calleeLoc.
70▶ todo := newQueue(len(b.allLocs) + 3)
71
72 enqueue := func(loc *location) {
· · ·
77 // which in some cases allows attrEscape to
78 // propagate faster.
79▶ todo.pushFront(loc)
80 } else {
81 todo.pushBack(loc)
· · ·
81▶ todo.pushBack(loc)
82 }
83 }
· · ·
85
86 for _, loc := range b.allLocs {
87▶ todo.pushFront(loc)
88 // TODO(thepudds): clean up setting queuedWalkAll.
89 loc.queuedWalkAll = true
· · ·
88▶ // TODO(thepudds): clean up setting queuedWalkAll.
89 loc.queuedWalkAll = true
90 }
+ 21 more matches in this file
61 slice, ok := reflect.TypeAssert[[]bool](v)
62 if !ok {
63▶ // It is kind bool but not type bool. TODO: We can handle this unsafely.
64 return false
65 }
· · ·
88 slice, ok := reflect.TypeAssert[[]complex64](v)
89 if !ok {
90▶ // It is kind complex64 but not type complex64. TODO: We can handle this unsafely.
91 return false
92 }
· · ·
117 slice, ok := reflect.TypeAssert[[]complex128](v)
118 if !ok {
119▶ // It is kind complex128 but not type complex128. TODO: We can handle this unsafely.
120 return false
121 }
· · ·
146 slice, ok := reflect.TypeAssert[[]float32](v)
147 if !ok {
148▶ // It is kind float32 but not type float32. TODO: We can handle this unsafely.
149 return false
150 }
· · ·
173 slice, ok := reflect.TypeAssert[[]float64](v)
174 if !ok {
175▶ // It is kind float64 but not type float64. TODO: We can handle this unsafely.
176 return false
177 }
+ 12 more matches in this file
165 astPkg := pkgs[pkg.Name]
166
167▶ // TODO: go/doc does not include typed constants in the constants
168 // list, which is what we want. For instance, time.Sunday is of type
169 // time.Weekday, so it is defined in the type but not in the
· · ·
709
710// bugs prints the BUGS information for the package.
711▶// TODO: Provide access to TODOs and NOTEs as well (very noisy so off by default)?
712func (pkg *Package) bugs() {
713 if pkg.doc.Notes["BUG"] == nil {
· · ·
856 // Print each spec only if there is at least one exported symbol in it.
857 // (See issue 11008.)
858▶ // TODO: Should we elide unexported symbols from a single spec?
859 // It's an unlikely scenario, probably not worth the trouble.
860 // TODO: Would be nice if go/doc did this for us.
· · ·
860▶ // TODO: Would be nice if go/doc did this for us.
861 specs := make([]ast.Spec, 0, len(value.Decl.Specs))
862 var typ ast.Expr
· · ·
1125 for _, iMethod := range inter.Methods.List {
1126 // This is an interface, so there can be only one name.
1127▶ // TODO: Anonymous methods (embedding)
1128 if len(iMethod.Names) == 0 {
1129 continue
+ 1 more matches in this file
101 // even though the type int was provided (not inferred) for P.
102 //
103▶ // TODO(gri) We might be able to finesse this in the error message reporting
104 // (which only happens in case of an error) and then avoid doing
105 // the substitution (which always happens).
· · ·
134 }
135 smap := makeSubstMap(tparams, targs)
136▶ // TODO(gri): pass a poser here, rather than arg.Pos().
137 inferred := check.subst(arg.Pos(), tpar, smap, nil, check.context())
138 // CannotInferTypeArgs indicates a failure of inference, though the actual
· · ·
167 // and continue, we may still be able to infer all
168 // targs resulting in fewer follow-on errors.
169▶ // TODO(gri) determine if we still need this check
170 continue
171 }
· · ·
258 // with the core type.
259 if !u.unify(tx, core.typ, 0) {
260▶ // TODO(gri) Type parameters that appear in the constraint and
261 // for which we have type arguments inferred should
262 // use those type arguments for a better error message.
· · ·
285 // and we may get a missing method error below. Skip this step in this case.
286 //
287▶ // TODO(gri) We should be able continue even with a parameterized tx if we add
288 // a simplify step beforehand (see below). This will require factoring out the
289 // simplify phase so we can call it from here.
+ 6 more matches in this file
96 }
97
98▶ // TODO(bradfitz,brainman): use ctx more. See TODO below.
99
100 var family int32 = syscall.AF_UNSPEC
· · ·
172 return r.addrs, r.err
173 case <-ctx.Done():
174▶ // TODO(bradfitz,brainman): cancel the ongoing
175 // GetAddrInfoW? It would require conditionally using
176 // GetAddrInfoEx with lpOverlapped, which requires
· · ·
189 }
190
191▶ // TODO(bradfitz): finish ctx plumbing
192 if err := acquireThread(ctx); err != nil {
193 return 0, newDNSError(mapErr(err), network+"/"+service, "")
· · ·
258 }
259
260▶ // TODO(bradfitz): finish ctx plumbing
261 if err := acquireThread(ctx); err != nil {
262 return "", newDNSError(mapErr(err), name, "")
· · ·
289 return r.goLookupSRV(ctx, service, proto, name)
290 }
291▶ // TODO(bradfitz): finish ctx plumbing
292 if err := acquireThread(ctx); err != nil {
293 return "", nil, newDNSError(mapErr(err), name, "")
+ 4 more matches in this file
104 // even though the type int was provided (not inferred) for P.
105 //
106▶ // TODO(gri) We might be able to finesse this in the error message reporting
107 // (which only happens in case of an error) and then avoid doing
108 // the substitution (which always happens).
· · ·
137 }
138 smap := makeSubstMap(tparams, targs)
139▶ // TODO(gri): pass a poser here, rather than arg.Pos().
140 inferred := check.subst(arg.Pos(), tpar, smap, nil, check.context())
141 // CannotInferTypeArgs indicates a failure of inference, though the actual
· · ·
170 // and continue, we may still be able to infer all
171 // targs resulting in fewer follow-on errors.
172▶ // TODO(gri) determine if we still need this check
173 continue
174 }
· · ·
261 // with the core type.
262 if !u.unify(tx, core.typ, 0) {
263▶ // TODO(gri) Type parameters that appear in the constraint and
264 // for which we have type arguments inferred should
265 // use those type arguments for a better error message.
· · ·
288 // and we may get a missing method error below. Skip this step in this case.
289 //
290▶ // TODO(gri) We should be able continue even with a parameterized tx if we add
291 // a simplify step beforehand (see below). This will require factoring out the
292 // simplify phase so we can call it from here.
+ 6 more matches in this file
60 slice, ok := reflect.TypeAssert[[]bool](v)
61 if !ok {
62▶ // It is kind bool but not type bool. TODO: We can handle this unsafely.
63 return false
64 }
· · ·
86 slice, ok := reflect.TypeAssert[[]complex64](v)
87 if !ok {
88▶ // It is kind complex64 but not type complex64. TODO: We can handle this unsafely.
89 return false
90 }
· · ·
111 slice, ok := reflect.TypeAssert[[]complex128](v)
112 if !ok {
113▶ // It is kind complex128 but not type complex128. TODO: We can handle this unsafely.
114 return false
115 }
· · ·
136 slice, ok := reflect.TypeAssert[[]float32](v)
137 if !ok {
138▶ // It is kind float32 but not type float32. TODO: We can handle this unsafely.
139 return false
140 }
· · ·
159 slice, ok := reflect.TypeAssert[[]float64](v)
160 if !ok {
161▶ // It is kind float64 but not type float64. TODO: We can handle this unsafely.
162 return false
163 }
+ 11 more matches in this file