Maria Krishtal
03/07/2024, 1:46 PMmbonnin
03/07/2024, 4:30 PMmaven(dependencyNotation)
was a thing. Or is it?
dependencies {
maven("g:a:v", exported = true)
}
Or is it made on purpose as a potential replacement of implementation
/`api`?
It's hard to have an opinion on the proposed syntax without more context how to interpret it.altavir
03/07/2024, 4:39 PMmbonnin
03/07/2024, 4:45 PMaltavir
03/07/2024, 4:48 PMsomething{ "A", "B"}
. I think that the same thing could be done in Kotlin without creating a new language. Because in the end, it will define how easy it is to customized the thing.CLOVIS
03/08/2024, 9:19 AMCLOVIS
03/08/2024, 9:20 AMexported
was supposed to mean? π€¦ββοΈ
I answered in like half the examples that api
/`implementation` was missing and that was very confusing, I never realized it was supposed to be that.vladimirsitnikov
03/08/2024, 4:23 PMCLOVIS
03/08/2024, 4:26 PMscope = runtimeOnly
argument, which I understand as the remplacement for everything other than api/implementation.CLOVIS
03/08/2024, 4:27 PMexported
to mean api
, it is indeed something many people are confused about, but maybe the form should have included some information on that.
It really does show that most of us understand snippets almost exclusively through naming familiarity, though.aurelien
03/09/2024, 1:57 PMaurelien
03/09/2024, 2:01 PMaurelien
03/09/2024, 2:05 PMaurelien
03/09/2024, 2:10 PMaltavir
03/10/2024, 6:49 AMGleb
03/10/2024, 9:53 AMDarryl Miles
03/10/2024, 5:48 PM@DslImplicitTypeConversionAllowed
to assist the compiler generating code where an object can be offered to a DSL API method to set a property, but the type doesn't have to match the property type (due to implicit conversion support being available in this area). At bit like having Property setter support being overload the accepted multiple types that can be the source of the data, while the backing field manages itself. This seems to be the main feature missing with the backend of the DSL. Because it allows helper methods to exist and then become hidden in the DSL syntax due to implicit type conversion the DSL user doesn't need to know, which specific helper method is needed to use in this specific context.
For the front end of the DSL (the parser) adding Groovy syntactic sugar, would be probably a trade off the individual DSL can decide to make. the syntax "something" { "item1", "item2" }
if we can hide the helper methods that can perform the necessary type conversions in the DSL backend (this is how implicit maybe used also)
As in it might make the DSL syntax opinionated at the expense of not supporting a particular Kotlin feature. There are a lot of these where that would be preferred to make the DSL more straight forward at the expense of Kotlin features available to be written directly into the DSL (like bring back the Groovy syntactic sugar items)
With JSON and Jackson library there a @JsonAnySetter
something similar would also be useful in DSL space that allow a method be marked to accept anything, allowing the object to be presented and allowing the DSL backend to decide if it can handle it and how. It is kind of an alternative and opposite to implicit conversion, in that it lets the data receiver deal with type conversion (but doing this reduces the quality of IDE DSL syntax support), but implicit conversion is better in that the data sender deals with type conversion (but you maintain high levels of IDE DSL syntax support at the same time); and it allow client extensions to the DSL to provide implicit that also just work and maintain highlevel of IDE DSL syntax content assist support.gildor
03/11/2024, 9:59 AMCLOVIS
03/11/2024, 10:13 AMRobin T
03/13/2024, 11:01 AMkotlin.sourceSets["main"].kotlin.srcDirs("main")
kotlin.sourceSets["test"].kotlin.srcDirs("test")
sourceSets["main"].resources.srcDirs("main")
sourceSets["test"].resources.srcDirs("test")
I also avoids deep packaging structures to achive simpler project strucutres like this:
project
βββ build.gradle.kts
βββ src
β βββ Main.kt
β βββ logback.xml
βββ test
βββ Main.kt
βββ logback-test.xml
This feels way less java-like and it gives smaller and easier-to-read project setups (opinionated).
The namespace-hell only makes sense when creating libraries that compete with popular libraries. Maven is polluted with transitive dependencies, this is really annoying and often only a veeeeery small fraction of the code in the transitive dependencies are used. Here Kotlin could make it harder to use java-libraries, and encourage the kotlin-community to replace it with something new.CLOVIS
03/13/2024, 12:39 PMHere Kotlin could make it harder to use java-libraries, and encourage the kotlin-community to replace it with something new.
Considering Kotlin got there mostly by being so friendly with the Java community to the point where they decided to jump ship, I don't believe this would be the right way forward.
Darryl Miles
03/13/2024, 1:54 PMCLOVIS
03/13/2024, 2:03 PMIf any proposed solution is truly better there is enough variety, options and freedom let allow the good stuff to rise.This is only true when software follows KISS and interoperability concerns. Say a new JVM debugger appeared tomorrow that was amazingly better than what we have today. Most of us probably still would use the one in IntelliJ, because, well, it's the one in IntelliJ. What I mean is, a build tool that doesn't have deep IntelliJ support may as well not exist.
Marcin Wisniowski
03/19/2024, 2:03 PMexported
to mean api
I think people are reading too much into this. The survey was about the abstract syntax, the identifiers (exported/maven) are just example names that have no meaning other than to show syntax differences.
At least that was my understanding of the survey.Darryl Miles
03/19/2024, 10:56 PMgildor
03/20/2024, 5:51 AMThe survey was about the abstract syntax, the identifiers (exported/maven) are just example names that have no meaning other than to show syntax differences.In this case survey should clearly state it, and I still don't see any reason for discussing it without all other, much more valuable details, this is absolutely miniscule detail comparing to rest of topic. Also I don't really like calling it
maven
either, but it was not discussed
At least that was my understanding of the surveyWe all guessing, and it makes it more confusing
just more on your "feeling" towards what you seeBut it's impossible without understanding of context, everyone start inventing context and looks that many don't like it, this why I called the research "flawed"
marlonlom
03/29/2024, 4:11 PMedrd
04/01/2024, 12:59 PMgildor
04/02/2024, 6:45 AMedrd
04/02/2024, 1:18 PMgildor
04/29/2024, 3:08 AMaltavir
04/29/2024, 6:32 AMgildor
04/29/2024, 6:34 AMaltavir
04/29/2024, 6:36 AMgildor
04/29/2024, 6:37 AMaltavir
04/29/2024, 6:43 AMgildor
04/29/2024, 6:47 AMgildor
04/29/2024, 6:47 AMaltavir
04/29/2024, 6:48 AMgildor
04/29/2024, 6:48 AMgildor
04/29/2024, 6:49 AMCLOVIS
04/29/2024, 6:53 AMgildor
04/29/2024, 7:20 AMgildor
04/29/2024, 7:24 AMgildor
04/29/2024, 7:26 AMaltavir
04/29/2024, 7:37 AMgildor
04/29/2024, 8:10 AMartem_zin
05/08/2024, 8:44 PMStarlark
in Bazel
& Buck
compared to Kotlin
& Groovy
in Gradle
.
I think it is essential for reproducible build system to have modern, compiled, statically-typed, side-effect-less configuration language and Kotlin can definitely be turned into that if needed as mentioned above: see https://github.com/buildfoundation/ketolang for an example of such dialect of Kotlin.
I also think it is extremely important to differentiate a dialect from a new programming language in case of Kotlin because the tooling, IDE support, etc will mostly βjust work β’οΈ β for a dialect of Kotlin with K2 compiler plugin architecture.gildor
05/09/2024, 2:59 AMCLOVIS
05/09/2024, 8:23 AMBut config language is one of the most important parts of those initiatives IMOI'd go further⦠from what we have seen, this is the only thing these initiatives have shown us anything about.