aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main/java/com/google/devtools/build/lib/skylarkinterface/Param.java
Commit message (Collapse)AuthorAge
* Javadoc that generic1 doesn't actually do what you'd expectGravatar brandjon2018-06-29
| | | | | RELNOTES: None PiperOrigin-RevId: 202692405
* Introduce Param.legacyNamed() to handle migration from @SkylarkSignature to ↵Gravatar cparsons2018-04-11
| | | | | | | | | | @SkylarkCallable. @SkylarkSignature.parameters() treat named()=true for parameters regardless of whether named() was actually set to true, and thus for ease of migration we mark migrated parameters as legacyNamed() = true, which is currently semantically equivalent to named() = true. We make a distinction so that it's easier to bulk fix these later. RELNOTES: None. PiperOrigin-RevId: 192477405
* Introduce extraPositonals and extraArguments to SkylarkCallable, to have ↵Gravatar cparsons2018-04-09
| | | | | | | | | parity with @SkylarkSignature. This is necessary for several builtin functions that still use @SkylarkSignature, such as string format. These will be migrated in a future CL. RELNOTES: None. PiperOrigin-RevId: 192200282
* Cleanup @SkylarkCallable parameters and their error handling.Gravatar cparsons2018-04-06
| | | | | | | This involves enforcing additional compiletime restrictions on Param ordering and semantics. RELNOTES: None. PiperOrigin-RevId: 191927206
* Force @SkylarkCallable Params with defaultValue = "None" to be noneable.Gravatar cparsons2018-03-20
| | | | | | | | Previously, usage was fairly inconsistent. From now on, if the @Param is mandatory, use defaultValue = "" instead. RELNOTES: None. PiperOrigin-RevId: 189777905
* Fix light typo in java docs.Gravatar dbabkin2017-12-14
| | | | | RELNOTES:none PiperOrigin-RevId: 179028810
* Replace js provider methods with named parameters.Gravatar Pedro Liberal Fernandez2016-08-29
| | | | | -- MOS_MIGRATED_REVID=131576962
* Display all allowed types for SkylarkSignature Params that allow multipleGravatar David Chen2016-07-05
| | | | | | | | | | | | | | | | | | | types. Fixes #921 Certain parameters, such as the `executable` and `command` parameters of ctx.action, allow multiple types. However, the allowed types are not enumerated in the SkylarkSignature annotation, causing the generated Skylark Library document to not display any type information for those params. This change adds a new field, `allowedTypes`, to `SkylarkSignature` that is a list of `ParamType` objects. If the param can accept multiple types, then `type` is set to `Object.class`, and `allowedTypes` is set to the list of types that can be accepted. -- MOS_MIGRATED_REVID=126617047
* Use only one list of parameters for SkylarkSignatureGravatar Damien Martin-Guillerez2016-06-14
| | | | | | | | | | | | | Optional and named parameters are now specified using `defaultValue` and `named` (and `positional`). The new structure allow for parameters that are both named and positional (which was forbidden before). This new structure will be used to give the @SkylarkCallable annotation the possibility to provide named and default arguments. It should be a functional no-op for Bazel users. -- MOS_MIGRATED_REVID=124821455
* Extract the @Param annotation from @SkylarkSignatureGravatar Damien Martin-Guillerez2016-06-10
The @SkylarkCallable annotation is very limited and to extend it it is best to share a similar API than the @SkylarkSignature annotation. -- MOS_MIGRATED_REVID=124473056