CodeMirror 2: C-like mode

    case 5: p(int) = zmq_getsockopt(p(socket), p(int), (void*)p(string), &p(len)); break;
 1
2
3
4
5
6
 
/* C demo code */
 
#include <zmq.h>
#include <pthread.h>
#include <semaphore.h>
#include <time.h>

Simple mode that tries to handle C-like languages as well as it can. Takes two configuration parameters: keywords, an object whose property names are the keywords in the language, and useCPP, which determines whether C preprocessor directives are recognized.

MIME types defined: text/x-csrc (C code), text/x-c++src (C++ code), text/x-java (Java code).