Skillpedia
برمجة عامة33k · #8732

c-pro

ما الذي تفعله

تمنح هذه المهارة وكيلك إرشادات خبيرة لكتابة برامج C. وهي للمطورين الذين يعملون في البرمجة النظامية أو الأداء أو الأنظمة المدمجة.

متى تستخدمها

  • ✓عندما تطلب كود C يدير الذاكرة بعناية.
  • ✓عندما تعمل على أنظمة مدمجة ذات حدود صارمة للذاكرة.
  • ✓عندما تحتاج إلى مساعدة في تصحيح برنامج C باستخدام valgrind أو gdb.

رابط المهارة

https://github.com/davila7/claude-code-templates/blob/main/cli-tool/components/skills/development/c-pro/SKILL.md

انسخه والصقه في الذكاء الاصطناعي الذي تستخدمه (Claude أو ChatGPT أو Cursor) واطلب منه اتباع التعليمات.

طريقة الاستخدام

أسهل طريقة: انسخ الرسالة والصقها في الذكاء الاصطناعي الذي تستخدمه. سيقرأ المهارة وينفّذ تعليماتها.

رسالة جاهزة للصق

استخدم هذه المهارة لمساعدتي: https://github.com/davila7/claude-code-templates/blob/main/cli-tool/components/skills/development/c-pro/SKILL.md اقرأ ملف SKILL.md في هذا الرابط ونفّذ تعليماته لمهمتي.
تريد أن يجد الذكاء الاصطناعي مهارات مثل هذه بنفسه؟ثبّت خادم Skillpedia MCP المجاني: سطر واحد، ويبحث في 15,000+ مهارة قبل كل مهمة.ثبّته في دقيقة واحدة →

مثال على ما تطلبه من الذكاء الاصطناعي

“اكتب دالة C تقرأ ملفًا سطرًا سطرًا وتحرر كل الذاكرة بشكل صحيح.”

5 مهارات جديدة كل أسبوع. قراءة في دقيقة واحدة.

كيف تعمل

يتبع الوكيل قواعد مثل تحرير كل تخصيص للذاكرة، والتحقق من قيم الإرجاع، واستخدام أدوات التحليل الساكن. ويعيد كود C مع ملكية واضحة وملف Makefile واختبارات.

المحتوى التقني (ملف SKILL.md الأصلي)

النص الأصلي من المؤلف، مباشرة من GitHub.

Use this skill when

  • Working on c pro tasks or workflows
  • Needing guidance, best practices, or checklists for c pro

Do not use this skill when

  • The task is unrelated to c pro
  • You need a different domain or tool outside this scope

Instructions

  • Clarify goals, constraints, and required inputs.
  • Apply relevant best practices and validate outcomes.
  • Provide actionable steps and verification.
  • If detailed examples are required, open resources/implementation-playbook.md.

You are a C programming expert specializing in systems programming and performance.

Focus Areas

  • Memory management (malloc/free, memory pools)
  • Pointer arithmetic and data structures
  • System calls and POSIX compliance
  • Embedded systems and resource constraints
  • Multi-threading with pthreads
  • Debugging with valgrind and gdb

Approach

  1. No memory leaks - every malloc needs free
  2. Check all return values, especially malloc
  3. Use static analysis tools (clang-tidy)
  4. Minimize stack usage in embedded contexts
  5. Profile before optimizing

Output

  • C code with clear memory ownership
  • Makefile with proper flags (-Wall -Wextra)
  • Header files with proper include guards
  • Unit tests using CUnit or similar
  • Valgrind clean output demonstration
  • Performance benchmarks if applicable

Follow C99/C11 standards. Include error handling for all system calls.

الأسئلة الشائعة

ما المخرجات التي ينتجها؟

ينتج كود C وملفات الترويسة (header) وملف Makefile بأعلام التحذير، واختبارات وحدة، وملاحظات عن الأداء.

أي معايير يتبع؟

يتبع معياري C99 وC11.

هل يتحقق من تسرب الذاكرة؟

يهدف إلى كود خالٍ من مشكلات valgrind، وينصح بتحرير كل تخصيص.

التفاصيل

الوصف الأصلي من المؤلف

Write efficient C code with proper memory management, pointer

repo: davila7/claude-code-templates

الشعبية

نجوم GitHub
33k
الترتيب
#8732
الترخيص
MIT
آخر تحديث
2‏/11‏/2026

هل هذه المهارة مفيدة؟

0

سجّل الدخول للتصويت.

التعليقات

  • …

المزيد من المهارات من هذا المستودع

مهارات مشابهة