伙计们,这段代码抛出了一个错误
daml 1.2
module PaidService where
template Service
with
provider : Party
beneficiary : Party
description : Text
cost : Decimal
currency : Text
where
signatory provider,beneficiary
controller beneficiary can
Transer : ContractId Service
with nextbeneficiary : Party
do
create this with beneficiary = nextbeneficiary
test_1 = scenario do
beth <- getParty "beth"
manish <- getParty "manish"
harsha <- getParty "harsha"
cid <- manish submit do
create Service
with
provider = manish
beneficiary = manish
description = "Yay"
cost = 1000.00
currency = "USD"
{ “资源”:“/home/Daml/learning/hackathon/daml/PaidService.daml”,“所有者”:“_generated_diagnostic_collection_name_#0”,“严重性”:8,“消息”:“/home//Daml/learning /hackathon/daml/PaidService.daml:27:3: 错误:\n 'do' 块中的最后一条语句必须是表达式\n cid <- manish\n submit\n do create\n Service\n {provider = manish, 受益人 = manish, description = \"Yay\",\n cost = 1000.00, currency = \"USD\"}", "source": "typecheck", "startLineNumber": 27, "startColumn": 3 , "endLineNumber": 34, "endColumn": 25 }
为什么会这样?