Skip to content

Commit a36884c

Browse files
author
Rick Whitner
committed
removed old skeleton.abi and changed skeleton.cpp to something that will compile and can be run by cleos
1 parent f4ed357 commit a36884c

File tree

2 files changed

+12
-54
lines changed

2 files changed

+12
-54
lines changed

contracts/skeleton/skeleton.abi

Lines changed: 0 additions & 39 deletions
This file was deleted.

contracts/skeleton/skeleton.cpp

Lines changed: 12 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,15 @@
1-
/**
2-
* @file
3-
* @copyright defined in eos/LICENSE.txt
4-
*/
5-
#include <skeleton.hpp>
1+
#include <eosiolib/eosio.hpp>
62

7-
/**
8-
* The init() and apply() methods must have C calling convention so that the blockchain can lookup and
9-
* call these methods.
10-
*/
11-
extern "C" {
3+
using namespace eosio;
124

13-
/// The apply method implements the dispatch of events to this contract
14-
void apply( uint64_t receiver, uint64_t code, uint64_t action ) {
15-
eosio::print( "Hello World: ", eosio::name(code), "->", eosio::name(action), "\n" );
16-
}
5+
class hello : public eosio::contract {
6+
public:
7+
using contract::contract;
178

18-
} // extern "C"
9+
/// @abi action
10+
void hi( account_name user ) {
11+
print( "Hello, ", name{user} );
12+
}
13+
};
14+
15+
EOSIO_ABI( hello, (hi) )

0 commit comments

Comments
 (0)