代码搜索:ptr
找到约 10,000 项符合「ptr」的源代码
代码结果 10,000
www.eeworm.com/read/221464/4829837
hpp is_shared_ptr.hpp
// Copyright David Abrahams 2003. Permission to copy, use,
// modify, sell and distribute this software is granted provided this
// copyright notice appears in all copies. This software is provided
www.eeworm.com/read/221464/4829849
hpp is_auto_ptr.hpp
// Copyright David Abrahams 2003. Permission to copy, use,
// modify, sell and distribute this software is granted provided this
// copyright notice appears in all copies. This software is provided
www.eeworm.com/read/221464/4829869
hpp borrowed_ptr.hpp
#ifndef BORROWED_PTR_DWA20020601_HPP
# define BORROWED_PTR_DWA20020601_HPP
// Copyright David Abrahams 2002. Permission to copy, use,
// modify, sell and distribute this software is granted provide
www.eeworm.com/read/221464/4831646
py auto_ptr.py
'''
>>> from auto_ptr_ext import *
>>> x = X(42)
>>> x.value()
42
>>> look(x), look(x)
(42, 42)
>>> maybe_steal(x, 0)
42
>>> look(x)
42
>>> maybe_steal(x, 1)
42
>>> broken_auto_ptr an
www.eeworm.com/read/221464/4831687
cpp register_ptr.cpp
#include
#include
using namespace boost;
using namespace python;
struct A
{
virtual int f() { return 0; }
};
shared_ptr New() { return
www.eeworm.com/read/221464/4831703
cpp shared_ptr.cpp
// Copyright David Abrahams 2002. Permission to copy, use,
// modify, sell and distribute this software is granted provided this
// copyright notice appears in all copies. This software is provided
www.eeworm.com/read/221464/4831715
cpp auto_ptr.cpp
// Copyright David Abrahams 2002. Permission to copy, use,
// modify, sell and distribute this software is granted provided this
// copyright notice appears in all copies. This software is provided
www.eeworm.com/read/221464/4831733
py shared_ptr.py
'''
>>> from shared_ptr_ext import *
Test that shared_ptr can be converted to shared_ptr
>>> Y.store(YYY(42))
>>> x = X(17)
>>> null_x = null(x)
>>> null_x # should be N
www.eeworm.com/read/221464/4831804
h smart_ptr.h
#ifndef SMART_PTR_H
#define SMART_PTR_H
#include
#include
namespace smart_ptr {
struct C
{
int value;
};
inline boost::shared_ptr NewC() {
www.eeworm.com/read/219395/4848358
c ptr2.c
/* Zeiger als Funktionsparameter */
#include
void quadrat(int *seite)
{
(*seite)*=(*seite);
}
int main()
{
int x;
printf("Bitte Seitenlaenge des Quadrats : ");
scanf(