- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 491 for Fact (0.04 sec)
-
test/typeparam/fact.go
package main import "fmt" func fact[T interface{ ~int | ~int64 | ~float64 }](n T) T { if n == 1 { return 1 } return n * fact(n-1) } func main() { const want = 120 if got := fact(5); got != want { panic(fmt.Sprintf("got %d, want %d", got, want)) } if got := fact[int64](5); got != want { panic(fmt.Sprintf("got %d, want %d", got, want)) }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Mar 01 19:45:34 UTC 2022 - 618 bytes - Viewed (0) -
src/cmd/vendor/golang.org/x/tools/internal/facts/facts.go
// TODO(adonovan): audit for other possibilities. logf("no object for path: %v; discarding %s", err, f.Fact) continue } key.obj = obj logf("read %T fact %s for %v", f.Fact, f.Fact, key.obj) } else { // package fact logf("read %T fact %s for %v", f.Fact, f.Fact, factPkg) } m[key] = f.Fact } } return &Set{pkg: d.pkg, m: m}, nil }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri May 03 02:38:00 UTC 2024 - 12.1K bytes - Viewed (0) -
src/cmd/vendor/golang.org/x/tools/go/analysis/analysis.go
ImportPackageFact func(pkg *types.Package, fact Fact) bool // ExportObjectFact associates a fact of type *T with the obj, // replacing any previous fact of that type. // // ExportObjectFact panics if it is called after the pass is // complete, or if obj does not belong to the package being analyzed. // ExportObjectFact is not concurrency-safe. ExportObjectFact func(obj types.Object, fact Fact)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Jun 04 16:19:04 UTC 2024 - 9.1K bytes - Viewed (0) -
src/cmd/vendor/golang.org/x/tools/go/analysis/validate.go
// that the Doc is not empty; // that the Run is non-nil; // that the Requires graph is acyclic; // that analyzer fact types are unique; // that each fact type is a pointer. // // Analyzer names need not be unique, though this may be confusing. func Validate(analyzers []*Analyzer) error { // Map each fact type to its sole generating analyzer. factTypes := make(map[reflect.Type]*Analyzer)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Nov 20 21:52:54 UTC 2023 - 3.1K bytes - Viewed (0) -
test/typeparam/factimp.dir/main.go
package main import ( "./a" "fmt" ) func main() { const want = 120 if got := a.Fact(5); got != want { panic(fmt.Sprintf("got %d, want %d", got, want)) } if got := a.Fact[int64](5); got != want { panic(fmt.Sprintf("got %d, want %d", got, want)) } if got := a.Fact(5.0); got != want { panic(fmt.Sprintf("got %f, want %f", got, want)) }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Mar 24 02:14:15 UTC 2022 - 516 bytes - Viewed (0) -
src/cmd/vendor/golang.org/x/tools/go/analysis/doc.go
associated either with an object or with a package: type Pass struct { ... ExportObjectFact func(types.Object, Fact) ImportObjectFact func(types.Object, Fact) bool ExportPackageFact func(fact Fact) ImportPackageFact func(*types.Package, Fact) bool } An Analyzer may only export facts associated with the current package or
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri May 03 02:38:00 UTC 2024 - 13.3K bytes - Viewed (0) -
maven-core/src/main/java/org/apache/maven/toolchain/DefaultToolchainManagerPrivate.java
throws MisconfiguredToolchainException { List<ToolchainPrivate> toRet = new ArrayList<>(); ToolchainFactory fact = factories.get(type); if (fact == null) { logger.error("Missing toolchain factory for type: " + type + ". Possibly caused by misconfigured project."); } else { List<ToolchainModel> availableToolchains =
Registered: Wed Jun 12 09:55:16 UTC 2024 - Last Modified: Wed Sep 06 08:39:32 UTC 2023 - 3.1K bytes - Viewed (0) -
analysis/analysis-api-impl-base/src/org/jetbrains/kotlin/analysis/api/impl/base/substitutorMarkers.kt
/** * A [KaSubstitutor] which substitution logic can be represented as a [Map] from a [KaTypeParameterSymbol] to corresponding [KaType] * This is an implementation details and Analysis API clients should not depend on the fact if some [KaSubstitutor] is [KaMapBackedSubstitutor] or not. */ @KaAnalysisApiInternals interface KaMapBackedSubstitutor : KaSubstitutor { /** * Substitution rules in a form of a `Map<KaTypeParameterSymbol, KaType>`
Registered: Wed Jun 12 09:53:16 UTC 2024 - Last Modified: Wed May 22 06:28:34 UTC 2024 - 1.4K bytes - Viewed (0) -
maven-core/src/main/java/org/apache/maven/toolchain/DefaultToolchainManager.java
Registered: Wed Jun 12 09:55:16 UTC 2024 - Last Modified: Wed Sep 06 08:39:32 UTC 2023 - 4.6K bytes - Viewed (0) -
platforms/documentation/docs/src/snippets/native-binaries/prebuilt/groovy/3rd-party-lib/util/README.txt
Registered: Wed Jun 12 18:38:38 UTC 2024 - Last Modified: Mon Nov 27 17:53:42 UTC 2023 - 195 bytes - Viewed (0)