1
0
Fork 0
mirror of https://github.com/ton-blockchain/ton synced 2025-03-09 15:40:10 +00:00

[FunC] Forbid auto-creating undefined symbols

This commit is contained in:
Aleksandr Kirsanov 2024-05-02 20:54:07 +03:00
parent 4994ae8edd
commit f217a7d312
No known key found for this signature in database
GPG key ID: B758BBAA01FFB3D3
7 changed files with 40 additions and 16 deletions

View file

@ -28,7 +28,8 @@
["jetton-minter/jetton-minter.fc", 9028309926287301331466371999814928201427184114165428257502393474125007156494]
["gg-marketplace/nft-marketplace-v2.fc", 92199806964112524639740773542356508485601908152150843819273107618799016205930]
["jetton-wallet/jetton-wallet.fc", 86251125787443633057458168028617933212663498001665054651523310772884328206542]
["whales-nominators/nominators.fc", 8941364499854379927692172316865293429893094891593442801401542636695127885153]
// (May 2024) reordered includes, they were in a wrong order
["whales-nominators/nominators.fc", 64989185004203073400683226767264384908045055609681310145961012819587514238303]
// (April 2024) tact hashes changed, because '__tact_address_eq()' is now inlined as a wrapper

View file

@ -8,8 +8,8 @@
#include "modules/store-validator.fc";
#include "modules/model.fc";
#include "modules/op-controller.fc";
#include "modules/op-owner.fc";
#include "modules/op-common.fc";
#include "modules/op-owner.fc";
#include "modules/op-nominators.fc";
#include "modules/get.fc";

View file

@ -0,0 +1,12 @@
int main(int x) {
return 1 + demo();
}
int demo() {
return 2;
}
{-
@compilation_should_fail
@stderr undefined symbol `demo`
-}

View file

@ -0,0 +1,10 @@
int main(int x) {
return 1 + demo;
}
global int demo;
{-
@compilation_should_fail
@stderr undefined symbol `demo`
-}

View file

@ -0,0 +1,10 @@
int demo(int x);
int main(int x) {
return 1 + demo(x);
}
{-
@compilation_should_fail
@stderr function `demo` is just declared, not implemented
-}