【发布时间】:2018-05-12 22:30:21
【问题描述】:
嗨,我想搜索页面上存在的所有功能语言,每个编程语言都列在一个表格中,我使用的页面是:https://en.wikipedia.org/wiki/Comparison_of_multi-paradigm_programming_languages#Paradigm_summaries
我将在两个元组中得到结果,我用来完成这个的代码是:
#r "/usr/lib/cli/fsharp/FSharp.Data.2.4.2/lib/net45/FSharp.Data.dll"
open FSharp.Data
type Multiparadigm = HtmlProvider<"https://en.wikipedia.org/wiki/Comparison_of_multi-paradigm_programming_languages#Paradigm_summaries">
let multi =
[ for x in Multiparadigm.GetSample().Tables.``Lenguage overview``.Rows ->
x.Type, x.``Functional`` ]
我将它保存在一个 .fsx 文件中,当我在 ubuntu 中使用 Fsharpc 时,我得到的错误是:
/Documents/Fsharp/testF#/getDataFPage.fsx(5,43): error FS0039: The field, constructor or member 'Languaje overview' is not defined
/Documents/Fsharp/testF#/getDataFPage.fsx(6,9): error FS0072: Lookup on object of indeterminate type based on information prior to this program point. A type annotation may be needed prior to this program point to constrain the type of the object. This may allow the lookup to be resolved.
/Documents/Fsharp/testF#/getDataFPage.fsx(6,17): error FS0072: Lookup on object of indeterminate type based on information prior to this program point. A type annotation may be needed prior to this program point to constrain the type of the object. This may allow the lookup to be resolved.
我想知道我做错了什么,因为在我得到的交互式工具中:
Referenced '/usr/lib/cli/fsharp/FSharp.Data.2.4.2/lib/net45/FSharp.Data.dll' (file may be locked by F# Interactive process)
【问题讨论】:
-
我正在使用 nuget 安装 FSharp.Data 并且已经在寻找它以确保 FSharp.Data.dll 位于正确的路径中
标签: types f# functional-programming