Age | Commit message (Collapse) | Author |
|
* Pass all contents of editorconfig to ktlint
* Enable trailing comma rules
|
|
* Update plugin kotlinBinaryCompatibilityValidator to v0.10.1
* :kotlinpoet:apiDump
* :interop:kotlinx-metadata:apiDump
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Egor Andreevici <egor@squareup.com>
|
|
|
|
|
|
|
|
Co-authored-by: Egor Andreevich <egor@squareup.com>
|
|
|
|
* Fix a bug caused by too long return expressions
* Fix a bug caused by too long return expressions
* Auto-identify extra spaces before and after return
* Auto-identify extra spaces before and after return
* Fix possible array out-of-bounds
* Making judgement easy
* add comments
* Update kotlinpoet/src/test/java/com/squareup/kotlinpoet/FunSpecTest.kt
Co-authored-by: Egor Andreevich <github@egorand.dev>
* Update kotlinpoet/src/main/java/com/squareup/kotlinpoet/FunSpec.kt
Co-authored-by: Egor Andreevich <github@egorand.dev>
* Update FunSpec.kt
* format if required
* spotless
Co-authored-by: yuejunyu <yuejunyu.0@bytedance.com>
Co-authored-by: Egor Andreevich <github@egorand.dev>
|
|
|
|
* Work around KT-52315
https://youtrack.jetbrains.com/issue/KT-52315
`header` and `impl` are deprecated and do not behave as modifier
keywords anymore... except in this specific case, seemingly.
* Simpler approach (escape everywhere)
* Rename test function to be more specific
Co-authored-by: Egor Andreevich <github@egorand.dev>
Co-authored-by: Egor Andreevich <github@egorand.dev>
|
|
annotations (#1247)
* Fix context receiver and annotation order @FunSpec
Prevent context receivers on accessors
Add FunSpec tests:
- Annotated function with context receiver
- Accessor with context receiver
Add context receivers to PropertySpec
Add PropertySpec tests:
- Var with context receiver
- Val without getter with context receiver
- Val with context receiver
- Annotated val with context receiver
* Fix code style
* Fix checks on var with context receivers and custom accessors
Update tests for vars with context receivers without custom accessors
Add test for var with context receivers and custom accessors
Fix code style
* Update kotlinpoet/src/main/java/com/squareup/kotlinpoet/PropertySpec.kt
Co-authored-by: Egor Andreevich <github@egorand.dev>
* Update tests
Co-authored-by: Egor Andreevich <github@egorand.dev>
|
|
* Update dependencies
* Fix type argument mapping when processing typealiases with KSP
|
|
* resolve enum constants
* reuse ClassName
* yikes, fix typo
* better comments
* Update kotlinpoet/src/main/java/com/squareup/kotlinpoet/CodeWriter.kt
Co-authored-by: Egor Andreevich <github@egorand.dev>
Co-authored-by: Egor Andreevich <github@egorand.dev>
|
|
* Add API for context receivers
* Use existing opt-in annotation and make context-receivers not nullable
* Remove collection overloads
* Revert unwanted code style changes
* Add wrongly remove @JvmOverloads annotation
* Add code generator and tests
* Apply requested changes
- Use proper experimental annotation
- Remove not needed overloads
- Move contextReceivers parameter to the end
* Update kotlinpoet/src/main/java/com/squareup/kotlinpoet/FunSpec.kt
Co-authored-by: Zac Sweers <pandanomic@gmail.com>
* Apply requested changes
- Add more tests
- Add new-line after context()
* Update test for suggestion
* Apply suggestions from code review
Co-authored-by: Egor Andreevich <github@egorand.dev>
* Apply requested changes
* Rename contextReceiver to contextReceivers
* Fix compiler error
* Update kotlinpoet/src/main/java/com/squareup/kotlinpoet/FunSpec.kt
Co-authored-by: Egor Andreevich <github@egorand.dev>
* Fix compiler errors in tests
* Run spotless
* Update kotlinpoet/src/main/java/com/squareup/kotlinpoet/LambdaTypeName.kt
Co-authored-by: Zac Sweers <pandanomic@gmail.com>
* Apply requested changes
* Don't emit context receiver spacing if there are no context receivers
* Apply suggestions from code review
Co-authored-by: Egor Andreevich <github@egorand.dev>
Co-authored-by: Zac Sweers <pandanomic@gmail.com>
Co-authored-by: Egor Andreevich <github@egorand.dev>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* Kotlin 1.6.0
* Update KCT
* Synthetic method annotations may not always be present
* typeNameOf not experimental anymore
Co-authored-by: Zac Sweers <pandanomic@gmail.com>
|
|
* Disallow enum constants and properties called "name" and "ordinal"
* Update kotlinpoet/src/main/java/com/squareup/kotlinpoet/TypeSpec.kt
* Fix tests
|
|
|
|
|
|
Fix #1076: Type names in a line comment may break the line
|
|
This allows these annotation specs' members to be more portable regardless of whether it's used as an annotation or constructor called. See https://github.com/square/moshi/pull/1390#issuecomment-944953034 for more details
|
|
|
|
|
|
* Configure Spotless to verify the presence of license headers
* Run spotlessApply to fill in missing license headers
|
|
* Extract TypeAliasTag for reuse and simplify API in KSP
* Update TestProcessor implementation for new alias API
This is based on the implementation for metadata in Moshi, and possibly worth promoting as a util to KotlinPoet itself
* I am once again asking IntelliJ to actually rename imports
* Spotless
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* update doc to mention kotlin-reflect
* Update docs/index.md
Co-authored-by: Egor Andreevich <github@egorand.dev>
* Update docs/index.md
Co-authored-by: Egor Andreevich <github@egorand.dev>
* Update kotlinpoet/src/main/java/com/squareup/kotlinpoet/TypeName.kt
Co-authored-by: Egor Andreevich <github@egorand.dev>
* Update kotlinpoet/src/main/java/com/squareup/kotlinpoet/ParameterizedTypeName.kt
Co-authored-by: Egor Andreevich <github@egorand.dev>
* Update index.md
Co-authored-by: Egor Andreevich <github@egorand.dev>
|
|
* Replace all http with https in apache licenses
* Replace all http with https in oracle docs
|
|
* Simplify tasks
* Remove kotlinDslPluginOptions
|
|
Fix by avoiding a short circuit and making sure we evaluate !alreadyEscaped
|
|
* Add MemberName.isExtension and update importing logic
* spotless
|
|
* Escape members that contains only underscores:
`data class(val `____`: String)`
* remove underscore keyword
* fix failed tests
* add allStringsAreEscaped test
* rename test
|
|
Fixes #1093
|
|
|
|
|
|
* Adding ability to changg initializers and defaultValues after initial set
* Making double initialization and similar possible
|
|
* Add a withIndent CodeBlock builder function.
* Remove the duplciated `the`
|
|
|