Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Nov 21 2020 23:30
    decapo01 closed #36
  • Nov 21 2020 23:30
    decapo01 commented #36
  • Nov 21 2020 23:29
    decapo01 edited #36
  • Nov 21 2020 15:06
    Ingo60 commented #36
  • Nov 21 2020 14:59
    Ingo60 commented #36
  • Nov 18 2020 04:36
    decapo01 opened #36
  • Oct 07 2020 08:54
    Dierk commented #392
  • Oct 07 2020 08:43
    szabi commented #392
  • Aug 02 2020 15:14
    Dierk commented #356
  • Aug 02 2020 13:45
    Dierk commented #356
  • Jul 30 2020 21:27
    Dierk commented #356
  • Jul 30 2020 08:46
    gilinykh commented #356
  • Jul 01 2020 21:22

    Dierk on master

    update README.adoc (compare)

  • Jul 01 2020 20:01

    Dierk on master

    added Frege_Gradle_Tasks.png (compare)

  • Jun 29 2020 15:09

    Dierk on master

    update images for the frege wik… (compare)

  • Jun 28 2020 13:47

    Dierk on master

    compiles and runs with frege-3.… upgrading to gradle 6.5 add images for the frege wiki p… (compare)

  • Jun 28 2020 12:18

    Dierk on master

    remove the duplicated line abou… small documentation clarificati… updating the comment around App… (compare)

  • Jun 24 2020 20:58
    Dierk edited #392
  • Jun 24 2020 20:50
    Dierk edited #392
  • Jun 24 2020 20:41
    Dierk edited #392
Ingo Wechsung
@Ingo60
  1. every constructor of a sum type would be a separate type.
  1. The sum type itself would be the union of all constructor types.
Ingo Wechsung
@Ingo60
  1. Every constructor type would be a subtype of any union type that contains it. Type inference could then infer the smallest union that would make the fields accessed or constructors mentioned safe. That is, for the unJustfunction above, it would infer Maybe{Just} a -> a, and this would preclude using the function on any value that can't be proven at compile time to be a Just
Ingo Wechsung
@Ingo60

Hence

unJust Nothing

would be a compile time error.
Until now, this is just fantasy. I'm not good enough in type theory to know if this could work at all, and maybe it would turn out that it is not practical.

Ingo Wechsung
@Ingo60
Apart from that, I don't have the time to do anything presently. I shall be happy to keep up with @matil019 's pull requests :)
Michael Chavinda
@mchav
I was looking into making a Frege port of Apache Beam. The implementation "serializes" functions and copies them to remote machines where they are then. They define the following function interface: https://beam.apache.org/releases/javadoc/2.13.0/org/apache/beam/sdk/transforms/SerializableBiFunction.html. Any opposition to rewriting Frege's Func class to follow a similar pattern?
I.e be serializable?
matil019
@matil019
Hi @mchav. From the logical point of view, I don't think it can be. The reason is the same as that an instance Show (a -> b) can't be defined.
However, perhaps you can write a conversion function something like SerializableBiFunction toSerializable(frege...Func<...> fun) or its equivalent in Frege.
Cary Robbins
@carymrobbins
Isn't this possible with something like StaticPointers?
Dierk König
@Dierk
we recently had a master project with Frege and Apache Spark where we needed the same but had to revert to sending code as text. If we could pull this off, it would be awesome!
Paul Kapustin
@pkapustin
@Ingo60 Sorry for delayed reply. Regarding records, I think what you are describing sounds a bit like dependent types. For example, in Idris Vector 0 Int and Vector 1 Int are both types of vectors (lists that have their length as part of their type) that hold Ints. They are different types belonging to the same family. Function head for vectors has signature Vect (S len) a -> a, meaning that the input vector cannot be empty.
@Ingo60 In my opinion, Frege probably does not need to go as far as dependent types.
Paul Kapustin
@pkapustin
@Ingo60 But I think that what you are discussing also is similar to rows, with structural subtyping. So, if type A has all the fields that B has, then B is a subtype. This is what Purescript's and Elm's extensible records are based on, so I was thinking that maybe it could be interesting to try some sort of extensibility like that in Frege.
@Frege However, I don't like that records in Purescript and Elm are typed only structurally. If I had to choose between nominally typed records like in Frege and structurally typed records like in Purescript or Elm, I would choose Frege's records. I suggested an idea how one could try to implement records with a mix of nominal and structural typing in Purescript.
https://discourse.purescript.org/t/allow-defining-named-records/1052/34
Paul Kapustin
@pkapustin
@Ingo60 Actually, I am very happy with records in Frege. For me possibilities of extension are interesting, but not important.
@Ingo60 When it comes to packages, I think it would be nice if we could come up with guidelines how to port Haskell code (where do we put the code and licenses)
Paul Kapustin
@pkapustin
@Dierk Just a kind reminder, how is it going with the server? I think it would be really nice to get things up and running again, especially thinking about services like "Try Frege" and "Hoogle".
Dierk König
@Dierk
@pkapustin thanks for the reminder ;-) Honestly, it would be great if anybody else could take over that task. In my task list it never quite rises above more urgent topics.
Ingo Wechsung
@Ingo60
@pkapustin Hi Paul, nice to see you. I'm afraid I don't understand enough Purescript to follow the discussion you linked to. Maybe I have to go for some sleep before I read it again.
mlnIGZlbGxhCg==
@0xde_gitlab
Are there plans to maintain support for Frege for JDK 11, 12, .., 14, etc.?
Ingo Wechsung
@Ingo60
x
Ingo Wechsung
@Ingo60
@0xde_gitlab I haven't tried 12 and above yet, but they should work fine. Most of the new features are meant to make human programmers happier, like, for example, type inference for locals. Such things are, of course, useless for us. The compiler doesn't mind writing the types out. So this would only break backwards compatibility without gaining anything. What could be interesting is the switch-expression, perhaps.
I'm still waiting for groundbreaking changes like proper tail calls, value types and primitives as type arguments. This would justify special support.
Meredith Espinosa
@Boundarybreaker
I'm trying to import frege and frege-interpreter in a Gradle project, but for some reason it's having trouble with the most recent version on sonatype. It's also running into a NoClassDefFoundError for frege/runtime/Lazy whenever I try to run the scripting engine. The environment is Java 8, with frege version 3.23.288-gaa3af0c and frege-interpreter version 1.2.1-SNAPSHOT. Is there anything I should know about or anywhere better to get a more up-to-date frege version?
(to note, 3.23.288-gaa3af0c is the highest version of frege I've been able to import, and sonatype just went down so I can't try higher versions again right now)
Ingo Wechsung
@Ingo60
@Boundarybreaker there is no current version on sonatype. If you need gradle, you'll have to configure it to use a local jar.
Michael Chavinda
@mchav
Any big milestones coming up language wise? With all this coronavirus stuff happening I have free time to work on some Frege.
Dierk König
@Dierk
@mchav we should bring up the online repl again.
Dierk König
@Dierk
I've installed an updated version of the Web Repl under http://86.119.37.112:9999 . I assume there will be issues that you can report at https://github.com/Frege/try-frege/issues . It currently runs under Java 8 (openjdk version "1.8.0_152") with frege3.24.405 (latest stable)
Dierk König
@Dierk
I updated the web repl again. It now uses the frege3.25.42.
I'd like the let try.frege-lang.org point to the new repl. Is anyone here the domain owner?
Michael Chavinda
@mchav
I'm trying to compile the Frege compiler and I run into a "Code too large" error. Can anyone else reproduce?
@Dierk did you find out who owns the domain?
Dierk König
@Dierk
@mchav you might need to increase the stack space. Last I checked the domain should now be available again or become available this month.
Sean Corfield
@seancorfield
Just coming back to Frege after a long break. Nice to see the Java 8 support (yes, I've been away a long time!). Is there a reason the Frege releases aren't on Maven or some easily accessible public repo?
Sean Corfield
@seancorfield
Clojure now has official CLI tooling (as an alternative to Leiningen) so I figured I'd update the Leiningen template to work with clj-new (the CLI equivalent). Both that and the frege-lein-plugin are based on 3.24-7.100 which is available on Sonatype (although browsing oss.sonatype.org I can't actually see anything except 3.23... which makes me wonder whether I published later versions on Clojars?)
(no, apparently I published a few 3.23 snapshots there)
I guess I could publish 3.24.405 to Clojars -- unless @Dierk has an objection to that?
Sean Corfield
@seancorfield
It looks like frege.compiler.Main/runCompiler still exists with the same signature so the plugin won't need to change much.
Dierk König
@Dierk
No objections from my side ;-)
Sean Corfield
@seancorfield
Thanks. I'll keep y'all posted on how it goes.
Dierk König
@Dierk
@seancorfield as for the maven repos: it is always a hassle to get things into maven central, sonartype, etc. Since Frege itself has no maven dependencies, we typically just fetch from the github release page. (btw: I guess one can expose github releases directly as mvn dependencies. There was a service called jitpack to facilitate this but maybe github can do this even directly)
Sean Corfield
@seancorfield
It turns out that I can no longer deploy Frege's JAR to Clojars because they no longer allow shadowing Maven artifacts -- and there are old versions of Frege up on Maven now. I would only be able to do it by pushing it up under a new group/artifact ID.
This suggests a way to read from a GitHub repo via Maven so I might try that from Clojure's build tooling and see how far I get: https://dzone.com/articles/using-github-as-maven-repository
Sean Corfield
@seancorfield
(rawgit no longer allows directory access and is going away so I'll have to keep poking some more)
Sean Corfield
@seancorfield
@Dierk It's looking like you can host Maven-style packages on GitHub via the Actions workflow (there's a maven.pkg.github.com domain) so I think that might be an interesting way to have builds of Frege happen automatically and have the artifacts hosted via GitHub Packages directly on the main repo (this is all new since I last looked at how to publish JAR files...)
Dierk König
@Dierk
@seancorfield cool. Let me see if I can find some time this week to try setting this up. It will be instructive either way.
Michael Chavinda
@mchav

With the deprecation of mutable has made my native definitions now look very clunky.

I went from:

data View = native mutable android.view.View where"
    native findViewById :: View -> Int -> IO View

To:

data View = native android.view.View where"
    native findViewById :: MutableIO View -> Int -> IO (MutableIO View)

Is there a way to make this look better syntactically?

alanmcsherry
@mcsherrylabs
Hello! I have a small Haskell project here https://github.com/input-output-hk/cardano-addresses, I'd like to cross compile it to a JVM compatible jar. Does that make any sense? Is this something Frege could or should do?
Dierk König
@Dierk
@mcsherrylabs cool project! What you can usually do in such cases is to just take your haskell code and run it through the Frege compiler with minimal changes. In your case though, you use some language extensions like MultiParamTypeClasses and TypeFamilies that Frege does not have, yet. That means that a Frege version of your library requires a bit more work than just renaming files -.)
1 reply