Skip to content

Commit 7560f6d

Browse files
lia-viamstuqdog
andauthored
Add instance comment boilerplate
Co-authored-by: Ethan <[email protected]>
1 parent eeac195 commit 7560f6d

File tree

1 file changed

+2
-0
lines changed
  • src/viam/examples/modules/simple

1 file changed

+2
-0
lines changed

src/viam/examples/modules/simple/main.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,8 @@ ProtoStruct MySensor::get_readings(const ProtoStruct&) {
7676
}
7777

7878
int main(int argc, char** argv) try {
79+
// Every Viam C++ SDK program must have one and only one Instance object which is created before
80+
// any other C++ SDK objects and stays alive until all Viam C++ SDK objects are destroyed.
7981
Instance inst;
8082

8183
Model mysensor_model("viam", "sensor", "mysensor");

0 commit comments

Comments
 (0)