• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C++ OS_UNUSED_ARG函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C++中OS_UNUSED_ARG函数的典型用法代码示例。如果您正苦于以下问题:C++ OS_UNUSED_ARG函数的具体用法?C++ OS_UNUSED_ARG怎么用?C++ OS_UNUSED_ARG使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了OS_UNUSED_ARG函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: idl_typedefOpenClose

static void
idl_typedefOpenClose(
    idl_scope scope,
    const char *name,
    idl_typeDef defSpec,
    void *userData)
{
    c_char spaces[20];
    idl_tmplExp te;
    OS_UNUSED_ARG(userData);

    OS_UNUSED_ARG(userData);

    if (((idl_typeSpecType(idl_typeDefRefered(defSpec)) == idl_tstruct) ||
         (idl_typeSpecType(idl_typeDefRefered(defSpec)) == idl_tunion)) &&
         (idl_streamsResolve(idl_streamsDefDefGet(), scope, name))) {
        /* keylist defined for this typedef of struct or union */
        te = idl_tmplExpNew(idlpp_macroSet);
        idl_macroSetAdd(idlpp_macroSet,
            idl_macroNew("namescope", idl_cxxId(idl_scopeElementName(idl_scopeCur(scope)))));
        idl_macroSetAdd(idlpp_macroSet, idl_macroNew("typename", idl_cxxId(name)));
        snprintf(spaces, sizeof(spaces), "%d", idlpp_indent_level*4);
        idl_macroSetAdd(idlpp_macroSet, idl_macroNew("spaces", spaces));
        idlpp_inStream = idl_streamInNew(idlpp_template, idlpp_macroAttrib);
        idl_tmplExpProcessTmpl(te, idlpp_inStream, idl_fileCur());
        idl_streamInFree(idlpp_inStream);
        idl_tmplExpFree(te);
    }
}
开发者ID:osrf,项目名称:opensplice,代码行数:29,代码来源:idl_genCxxStreamsIdl.c


示例2: idl_unionOpen

static idl_action
idl_unionOpen(
    idl_scope scope,
    const char *name,
    idl_typeUnion unionSpec,
    void *userData)
{
    c_char spaces[20];
    idl_tmplExp te;

    OS_UNUSED_ARG(unionSpec);
    OS_UNUSED_ARG(userData);

    /* QAC EXPECT 3416; No side effects here */
    if (idl_streamsResolve(idl_streamsDefDefGet(), scope, name)) {
    /* keylist defined for this union */
        te = idl_tmplExpNew(idlpp_macroSet);
        idl_macroSetAdd(idlpp_macroSet,
            idl_macroNew("namescope", idl_cxxId(idl_scopeElementName(idl_scopeCur(scope)))));
        idl_macroSetAdd(idlpp_macroSet, idl_macroNew("typename", idl_cxxId(name)));
        idl_macroSetAdd(idlpp_macroSet, idl_macroNew("scopedtypename", idl_scopeStack(scope, "::", name)));
        snprintf(spaces, sizeof(spaces), "%d", idlpp_indent_level*4);
        idl_macroSetAdd(idlpp_macroSet, idl_macroNew("spaces", spaces));
        idlpp_inStream = idl_streamInNew(idlpp_template, idlpp_macroAttrib);
        idl_tmplExpProcessTmpl(te, idlpp_inStream, idl_fileCur());
        idl_streamInFree(idlpp_inStream);
        idl_tmplExpFree(te);
    }
    return idl_abort;
}
开发者ID:osrf,项目名称:opensplice,代码行数:30,代码来源:idl_genCxxStreamsDefs.c


示例3: cmx_participantDetach

static c_ulong
cmx_participantDetach(
    u_observable o,
    c_ulong event,
    c_voidp usrData)
{
    v_serviceStateKind kind;
    u_serviceManager manager;

    OS_UNUSED_ARG(o);
    OS_UNUSED_ARG(event);
    OS_UNUSED_ARG(usrData);

    if ((event & V_EVENT_SERVICESTATE_CHANGED) == V_EVENT_SERVICESTATE_CHANGED) {
        if(cmx_isInitialized() == TRUE){
            manager = (u_serviceManager)usrData;

            if(manager != NULL){
                kind = u_serviceManagerGetServiceStateKind(manager, V_SPLICED_NAME);

                if ((kind != STATE_INITIALISING) && (kind != STATE_OPERATIONAL)) {
                    cmx_internalDetach();
                    u_objectFree(manager);
                    manager = NULL;
                }
            }
        }
    }
    return event;
}
开发者ID:osrf,项目名称:opensplice,代码行数:30,代码来源:cmx_participant.c


示例4: dummy_callback

static void
dummy_callback(
    v_public p,
    c_voidp arg)
{
    OS_UNUSED_ARG(p);
    OS_UNUSED_ARG(arg);
}
开发者ID:lsst-ts,项目名称:ts_opensplice,代码行数:8,代码来源:MiscUtils.cpp


示例5: dds_init

int dds_init (
    int argc,
    char ** argv)
{
    OS_UNUSED_ARG(argc);
    OS_UNUSED_ARG(argv);
    return 0;
}
开发者ID:osrf,项目名称:opensplice,代码行数:8,代码来源:dds_main.c


示例6: OS_UNUSED_ARG

unsigned char
DDS::OpenSplice::ReadCondition::test_sample_states (
    c_object o,
    c_voidp args)
{
    OS_UNUSED_ARG(o);
    OS_UNUSED_ARG(args);
    return true; /* state evaluation is now in the kernel. */
}
开发者ID:osrf,项目名称:opensplice,代码行数:9,代码来源:ReadCondition.cpp


示例7: os_threadStopCallback

static int
os_threadStopCallback(
    os_threadId id,
    void *arg)
{
    OS_UNUSED_ARG(id);
    OS_UNUSED_ARG(arg);
    return 0;
}
开发者ID:osrf,项目名称:opensplice,代码行数:9,代码来源:os_thread.c


示例8: c_mmUnbind

void
c_mmUnbind(
    c_mm mm,
    const c_char *name)
{
    assert(0);
    OS_UNUSED_ARG(mm);
    OS_UNUSED_ARG(name);
}
开发者ID:AmitShah,项目名称:opensplice,代码行数:9,代码来源:c_mmbase.c


示例9: idl_moduleOpen

static idl_action
idl_moduleOpen (
    idl_scope scope,
    const char *name,
    void *userData)
{
    c_ulong streamsIndex, streamsCount;
    idl_action result;
    OS_UNUSED_ARG(userData);

    OS_UNUSED_ARG(userData);

    /* Test whether the module contains a component within the pragma streams.
     * If it does not, then the module should not be generated since it will
     * contain no items (which is itself illegal idl syntax).
     *
     * Note that we are comparing against only the streams existing within this idl
     * file (idl_idlScopeStreamsList).  We do not use the result of idl_keyDefDefGet()
     * since this is a list of streams resulting from the preprocessed idl (which
     *  will include streams from other idl files that this may include).
     */
    result = idl_abort;
    streamsCount = os_iterLength(idl_idlScopeStreamsList);
    if (streamsCount != 0) {
        idl_scope moduleScope;
        idl_scopeElement newElement;

        /* the idl_scope parameter to this function does not yet include the scoping
         * for this module itself, so create a duplicate and add this scoping to it,
         * before testing whether this module contains one of the streams in this file.
         */
        moduleScope = idl_scopeDup(scope);
        newElement = idl_scopeElementNew(name, idl_tModule);
        idl_scopePush(moduleScope, newElement);

        /* Loop through the list of keys applying to this idl file and test whether
         * this particular module contains one of these keys.  If it does, generate
         * code for the module.
         */
        for (streamsIndex = 0; (streamsIndex < streamsCount) && (result == idl_abort); streamsIndex++) {
            idl_scope streamsScope = os_iterObject(idl_idlScopeStreamsList, streamsIndex);
            if (idl_scopeSub(moduleScope, streamsScope)) {
                /* Scopes match */
                result = idl_explore;
            }
        }
    }

    if (result == idl_explore) {
        idl_printIndent(idlpp_indent_level);
        idl_fileOutPrintf(idl_fileCur(), "module %s {\n", idl_cxxId(name));
        idl_fileOutPrintf(idl_fileCur(), "\n");
        idlpp_indent_level++;
    }
    return result;
}
开发者ID:osrf,项目名称:opensplice,代码行数:56,代码来源:idl_genCxxStreamsIdl.c


示例10: os_mmfResize

os_result
os_mmfResize(
    os_mmfHandle mmfHandle,
    os_uint32 new_size)
{
    OS_UNUSED_ARG (mmfHandle);
    OS_UNUSED_ARG (new_size);
    OS_REPORT(OS_INFO, "os_mmfResize", 0, "NOT IMPLEMENTED");
    return os_resultUnavailable;
}
开发者ID:osrf,项目名称:opensplice,代码行数:10,代码来源:os_memMapFileNotImplemented.c


示例11: os_mmfCreateHandle

os_mmfHandle
os_mmfCreateHandle (
    const char *filename,
    const os_mmfAttr *mmfAttr)
{
    OS_UNUSED_ARG (filename);
    OS_UNUSED_ARG (mmfAttr);
    OS_REPORT(OS_INFO, "os_mmfCreateHandle", 0, "NOT IMPLEMENTED");
    return NULL;
}
开发者ID:osrf,项目名称:opensplice,代码行数:10,代码来源:os_memMapFileNotImplemented.c


示例12: OS_UNUSED_ARG

void
DDS::OpenSplice::DataReaderView::nlReq_notify_listener (
    DDS::OpenSplice::Entity *sourceEntity,
    DDS::ULong               triggerMask,
    void                    *eventData)
{
    OS_UNUSED_ARG(sourceEntity);
    OS_UNUSED_ARG(triggerMask);
    OS_UNUSED_ARG(eventData);
}
开发者ID:lsst-ts,项目名称:ts_opensplice,代码行数:10,代码来源:DataReaderView.cpp


示例13: os_signalHandlerRegisterCheckExceptionCallback

os_signalHandlerExceptionHandle
os_signalHandlerRegisterCheckExceptionCallback(
    os_signalHandlerExceptionCallback callback,
    void * arg)
{
    OS_UNUSED_ARG(callback);
    OS_UNUSED_ARG(arg);

    return os_signalHandlerExceptionHandleNil;
}
开发者ID:osrf,项目名称:opensplice,代码行数:10,代码来源:os__signalHandler.c


示例14: os_mmfCreate

os_result
os_mmfCreate(
    os_mmfHandle mmfHandle,
    os_address size)
{
    OS_UNUSED_ARG (mmfHandle);
    OS_UNUSED_ARG (size);
    OS_REPORT(OS_INFO, "os_mmfCreate", 0, "NOT IMPLEMENTED");
    return os_resultUnavailable;
}
开发者ID:osrf,项目名称:opensplice,代码行数:10,代码来源:os_memMapFileNotImplemented.c


示例15: idl_moduleOpen

static idl_action
idl_moduleOpen(
    idl_scope scope,
    const char *name,
    void *userData)
{
    OS_UNUSED_ARG(scope);
    OS_UNUSED_ARG(name);
    OS_UNUSED_ARG(userData);

    return idl_explore;
}
开发者ID:osrf,项目名称:opensplice,代码行数:12,代码来源:idl_genSajTypedClass.c


示例16: idl_moduleClose

static void
idl_moduleClose(
    void *userData)
{
    OS_UNUSED_ARG(userData);

    /* this is only executed if idl_moduleOpen returns 'idl_explore' */
    OS_UNUSED_ARG(userData);
    idlpp_indent_level--;
    idl_printIndent(idlpp_indent_level);
    idl_fileOutPrintf(idl_fileCur(), "};\n");
    idl_fileOutPrintf(idl_fileCur(), "\n");
}
开发者ID:osrf,项目名称:opensplice,代码行数:13,代码来源:idl_genCxxStreamsIdl.c


示例17: idl_moduleOpen

static idl_action
idl_moduleOpen(
    idl_scope scope,
    const char *name,
    void *userData)
{
    OS_UNUSED_ARG(scope);
    OS_UNUSED_ARG(userData);

    idl_printIndent(idlpp_indent_level);
    idl_fileOutPrintf(idl_fileCur(), "namespace %s {\n", idl_cxxId(name));
    idl_fileOutPrintf(idl_fileCur(), "\n");
    idlpp_indent_level++;
    return idl_explore;
}
开发者ID:osrf,项目名称:opensplice,代码行数:15,代码来源:idl_genCxxStreamsDefs.c


示例18: v_deliveryServiceEntryWrite

v_writeResult
v_deliveryServiceEntryWrite(
    v_deliveryServiceEntry _this,
    v_message message,
    v_instance *instancePtr)
{
    v_deliveryInfoTemplate ackMsg;
    v_writeResult result = V_WRITE_REJECTED;
    v_reader reader;

    OS_UNUSED_ARG(instancePtr);
    assert(C_TYPECHECK(_this,v_deliveryServiceEntry));
    assert(message != NULL);

    /* Only write if the message is not produced by an incompatible writer. */
    reader = v_entryReader(_this);
    OSPL_LOCK(reader);

    /* Filter-out all QoS-incompatible messages. */
    if (!v_messageQos_isReaderCompatible(message->qos,reader)) {
        OSPL_UNLOCK(reader);
        return V_WRITE_SUCCESS;
    }

    /* If Alive then claim instance and trigger with sample event. */
    ackMsg = (v_deliveryInfoTemplate)message;
    result = v_deliveryServiceWrite(v_deliveryService(reader),ackMsg);

    OSPL_UNLOCK(reader);

    return result;
}
开发者ID:osrf,项目名称:opensplice,代码行数:32,代码来源:v_deliveryServiceEntry.c


示例19: v_topicAdapterNotify

void
v_topicAdapterNotify(
    v_topicAdapter adapter,
    v_event event,
    c_voidp userData)
{
    C_STRUCT(v_event) e;
    c_bool forward = TRUE;

    OS_UNUSED_ARG(userData);
    assert(adapter != NULL);
    assert(C_TYPECHECK(adapter,v_topicAdapter));
    assert(event != NULL);

    switch (event->kind) {
    case V_EVENT_ALL_DATA_DISPOSED:
        v_statusNotifyAllDataDisposed(v_entity(adapter)->status);
    break;
    case V_EVENT_INCONSISTENT_TOPIC:
        v_statusNotifyInconsistentTopic(v_entity(adapter)->status);
    break;
    default:
        forward = FALSE;
    break;
    }
    if (forward) {
        e.kind = event->kind;
        e.source = v_observable(adapter);
        e.data = NULL;
        (void)v_entityNotifyListener(v_entity(adapter), &e);
    }
}
开发者ID:osrf,项目名称:opensplice,代码行数:32,代码来源:v_topicAdapter.c


示例20: d_objectFree

void
d_objectFree(
    d_object object,
    d_kind kind)
{
    os_uint32 refCount;

    OS_UNUSED_ARG(kind);
    assert(d_objectIsValid(object, kind) == TRUE);

    if(object){
       assert(object->confidence == D_CONFIDENCE);
       assert(object->kind == kind);
       assert(object->refCount >= 1);

       refCount = pa_decrement(&(object->refCount));

       if(refCount == 0){
           if(object->deinit){
               object->deinit(object);
           }
           object->confidence = D_CONFIDENCE_NULL;
           object->kind = D_BAD_TYPE;
           os_free(object);
           assert(doSub(kind));
       }
#if CHECK_REF
       if (kind == CHECK_REF_TYPE) {
           UT_TRACE("\n\n============ Free(%p): %d -> %d =============\n",
                   (void*)object, refCount+1, refCount);
       }
#endif
    }
}
开发者ID:S73417H,项目名称:opensplice,代码行数:34,代码来源:d_object.c



注:本文中的OS_UNUSED_ARG函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C++ OTSYS_TIME函数代码示例发布时间:2022-05-30
下一篇:
C++ OS_TS_GET函数代码示例发布时间:2022-05-30
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap