Sublime Forum

Sanitizers in c++ in Sublime text 3

#1

Hello community members !!

Recently I have started doing competitive programming and giving a lot of contests. And in doing so I have encountered a lot of errors, mostly of them being segmentation faults.

And I was looking for a method to incorporate sanitizers and flags which are pretty useful for people like me. But I didn’t find any. So please help me out in this one.

0 Likes

#2

You can make a custom build system to add whatever flags you want: https://www.sublimetext.com/docs/3/build_systems.html

1 Like

#3

Can you please show me some sample build file ?

And also the default build for c++ files in sublime text 3 ?

It would be a great help.

0 Likes

#4

Just use the View Package File option from the command palette. Searching for C++/.sublime-build after using View Package File should show you the default C++ build file. Similarly, you can see it for any of the default shipped language build files.

1 Like