Skip to content

Commit

Permalink
adds usage section for cpp converter (bmw-software-engineering#44)
Browse files Browse the repository at this point in the history
adds usage section
  • Loading branch information
christophkloeffel authored Jun 26, 2024
1 parent d3c618e commit aabda94
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 1 deletion.
2 changes: 1 addition & 1 deletion lobster/tools/cpp/cpp.py
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ def main():
kind = kind,
name = function_name)

db[tag.key].just_up.append(reason)
db[tag.key()].just_up.append(reason)

continue

Expand Down
30 changes: 30 additions & 0 deletions packages/lobster-tool-cpp/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,36 @@ future.
* `lobster-cpp`: Extract requirements from C/C++ code using a
clang-tidy hack

## Usage

This tool supports C/C++ code.

For this you can embedd tracing tags like this:

```cpp
#include <string>
class Potato {
public:
std::string potato() {
// lobster-trace: something.example
return "potato";
}
};
```
You can add justifications as well:
```cpp
#include <string>
class Potato {
public:
std::string potato() {
// lobster-exclude: Reason to justify the exlude
return "potato";
}
};
```

## Copyright & License information

The copyright holder of LOBSTER is the Bayerische Motoren Werke
Expand Down

0 comments on commit aabda94

Please sign in to comment.