Giter VIP home page Giter VIP logo

csubsub's Introduction

CSubSub

C语言面向对象库

#为什么要使用C--

  1. C--完全使用C语言开发,高效、快速
  2. C++越来越复杂,概念越来越多,给人的感觉就像是一个天生有病的人,在后天又用各种方式去治疗,导致这个病人伤痕累累、体无完肤,好像说得有点儿过了,但是事实上是因为C++概念太多,用法太多,学起来太不人性了,爱因斯坦说过,这个世界上任何看似复杂的存在,都有一个简单的解释,那么按这一原则来说,C++设计得太逆天了
  3. 用C--可以写出完美的面向对象的程序
  4. 一起来拥抱简洁完美的C语言吧

#C--的自动释放机制

  1. 如果指定一个对象为自动释放(autorelease)的话,cssSystem会将该对象记录
  2. 在执行cssCall(cssSystemGetInstance(), gc)时,所有记录的对象都将被释放

#HelloWorld示例代码如下:

#include <stdio.h>
#include "css.h"

#include <stdio.h>
#include "css.h"

int main(int argc, const char * argv[])
{
    
    cssCall(cssSystemGetInstance(), logOn);
    
    cssString * str = cssStringCreateWithCString("Hello World");
    
    // insert code here...
    printf("%s\n",cssCall(str, getCString));
    
    cssCall(cssSystemGetInstance(), gc);
    return 0;
}

csubsub's People

Contributors

plter avatar

Watchers

高亚斌 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.