Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • 03:45
    smoothdeveloper labeled #10535
  • 03:45
    smoothdeveloper opened #10535
  • 03:22

    cartermp on main

    Use MEF instead of GetService c… (compare)

  • 03:22
    cartermp closed #10531
  • 03:04

    dotnet-bot on main-to-release

    (compare)

  • 03:04

    dotnet-bot on main-to-release

    (compare)

  • 03:04

    dotnet-bot on release

    (compare)

  • 03:04

    dotnet-bot on release

    (compare)

  • 03:04

    dotnet-bot on dev16.0-to-main

    (compare)

  • 03:04

    dotnet-bot on dev16.0-to-main

    (compare)

  • 02:48
    cartermp synchronize #10518
  • 02:48
    cartermp edited #10518
  • 01:52
    cartermp synchronize #10518
  • 00:51

    dotnet-bot on main-to-release

    (compare)

  • 00:51

    dotnet-bot on main-to-release

    (compare)

  • 00:51

    dotnet-bot on release

    (compare)

  • 00:51

    dotnet-bot on release

    (compare)

  • 00:51

    dotnet-bot on dev16.0-to-main

    (compare)

  • 00:51

    dotnet-bot on dev16.0-to-main

    (compare)

  • 00:50
    cartermp edited #10518
robertj
@robkuz

In the above example at the moment I would have to create a specialized impl for any combination of 'a and 'b of Foo<_> whereas with an implementation like MapFoo I just need the functions that do the conversion and give one of these functions during construction time
So my question is: are there any hard technical limitations (CLR/.NET) or type theory or type inferrence that prevents this? And if so why is it even possible to define the interface like

type IMap =
     abstract member Map: 'a -> 'b

Why not have a compiler error when trying to define a generic abstract method that uses generic types that are not defined on the type itself?

Yemi Bedu @ P&R
@pr-yemibedu
@robkuz https://stackoverflow.com/questions/8115470/creating-and-using-a-generic-function-in-a-non-generic-f-interface and http://codebetter.com/matthewpodwysocki/2009/05/08/type-classes-are-the-secret-sauce/ F# does not have type classes. So you can not have a generic Add interface that both Number and String implementations source from. I am not sure why it compiles the interface itself as it always needs an obj that you can not cast to (like int).
Victor Peter Rouven Müller
@realvictorprm
Shouldn't traits be able to fix this in future
Onur Gumus
@OnurGumus
As an idea, don't you think it would have been better if akka.net used rx.net schedulers
This way we could have completed control over time.
Onur Gumus
@OnurGumus
Wrong channel
Robert Maxton
@robertmaxton42
Hey guys! I'm an F# newbie playing around in Visual Studio Code
Is this the right place?
Avi Avni
@AviAvni
Join fsharp software foundation slack
@robertmaxton42 ^
Robert Maxton
@robertmaxton42
@AviAvni Er.... how? Never used Slack before, sorry
Avi Avni
@AviAvni
@robertmaxton42 start http://foundation.fsharp.org/join
Robert Maxton
@robertmaxton42
@AviAvni Thanks!
Yemi Bedu @ P&R
@pr-yemibedu
@robertmaxton42 you can look here too if slack is overwhelming. ionide-project channel may come in handy if you have issues with their extension for vscode.
ShalokShalom
@ShalokShalom
You can also look in the Fable channel here, if the question relates to it
td-ideabox
@td-ideabox
Sorry if this is super obvious but how do I create a cli executable from an F# solution/project? Like I have source that builds in Rider, but the bin directory doesn't have anything that looks like something I could execute with ./myscript
I see a dll and pdb file and stuff
Victor Peter Rouven Müller
@realvictorprm
Are you in Unix?
td-ideabox
@td-ideabox
Yeah OSX
Victor Peter Rouven Müller
@realvictorprm
You must use .net core or mono to run an exe file
td-ideabox
@td-ideabox
k, so I used msbuild myscript.sln and it seemed to do a thing, what do I do after that?
Victor Peter Rouven Müller
@realvictorprm
E.g. for mono you simply type mono myapp.exe
td-ideabox
@td-ideabox
mono <something> ?
K, I don't see a .exe anywhere,
Victor Peter Rouven Müller
@realvictorprm
Is this a project generating a library?
td-ideabox
@td-ideabox
There is definitely a .dll generated
So I'm guessing I need to change a build setting or something?
Also thanks for your time!
Victor Peter Rouven Müller
@realvictorprm
Looks like. Sure no problem
td-ideabox
@td-ideabox
K, I'm working in Rider. Couldn't get things to play nice in Ionide.
I chose a Console Application
Victor Peter Rouven Müller
@realvictorprm
Console Application should work out
Alternatively you can try running the all although I'm a bit confused at this point :smile:
*dll=all
td-ideabox
@td-ideabox
So give mono <something>.dll a shot, k
Hmm, didn't do anything.
Victor Peter Rouven Müller
@realvictorprm
:confused: darn
I'm not familiar with Rider
Alternatively ask on the fsharp forums or in the Fsharp slack :smiley:
td-ideabox
@td-ideabox
Hah! so looking at the Rider output running a build, the command to get things happening is dotnet something.dll
And it works!
Thanks for rubberducking for me @realvictorprm !
Victor Peter Rouven Müller
@realvictorprm
Ah dotnet ja tue command kg used with .Met Code
Sorry german keyboard lol
No problem, I'm glad it works now for you :+1:
td-ideabox
@td-ideabox
So I can't get Ionide to see the packages I'm adding with Paket on OSX. Here's a vid of me creating a fresh project and trying to get JsonProviders, am I doing something wrong?
sorry wrong chat :-D
Leo Cavalcante
@leocavalcante

Hi folks, I'm reading about F# and trying to apply it to my daily job.
I was already been able to load a CSV file with the help of FSharp.Data from NuGet, but I did it a imperative style, I think. Now I'm trying to apply functional constructs, tried the following:

open System
open System.IO
open FSharp.Data

[<EntryPoint>]
let main argv =
  let data =
    argv.[0]
    |> Path.Combine Environment.CurrentDirectory
    |> CsvFile.Load

  printfn "%A" data.Headers

  0

What I'm missing here?
In my head argv.[0] is passed to the result of Path.Combine Environment.CurrentDirectory which curried already have the current dir as the first path then the combined result is given to CsvFile.Load.
Did I get |> and curring wrong?